bugGNU Common Lisp - Bugs: bug #63850, Don't set deployment target on...

 
 

bug #63850: Don't set deployment target on non-PowerPC macOS

Submitter:  Ryan Carsten Schmidt <ryandesign>
Submitted:  Tue 28 Feb 2023 11:03:50 PM UTC
   
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  Fixed
Privacy:  Public Assigned to:  None
Open/Closed:  Closed
* Mandatory Fields

Add a New Comment Rich Markup
   

Fri 02 Feb 2024 02:12:30 PM UTC, comment #2: 

Greetings!  Fix posted in master/Version_2_7_0pre.

Camm Maguire <camm>
Group administrator
Sun 28 Jan 2024 02:25:22 PM UTC, comment #1: 

Greetings, and thanks for your report!  Will be fixed in next release.

Camm Maguire <camm>
Group administrator
Tue 28 Feb 2023 11:03:50 PM UTC, original submission:  

The files h/386-macosx.defs and h/powerpc-macosx.defs contain these lines:


# Set this for the linker to operate correctly.
MACOSX_DEPLOYMENT_TARGET = 10.2


These lines should be removed from h/386-macosx.defs where they have never served any purpose and cause build failures on recent systems. In h/powerpc-macosx.defs you may want to change it so that you only set it if the user has not already set it, and as explained below you may want to set it only if the Mac OS X version is less than 10.5.

This was part of the commit that added Mac build support back in July 2003:

http://git.savannah.gnu.org/cgit/gcl.git/commit/?id=b54cbfe43d04f84c53c6e211a763b8e02185f4fc

At that time the current version of Mac OS X was 10.2. The deployment target feature had just been introduced in Mac OS X 10.1. The deployment target is the earliest Mac OS X version on which the program you're compiling should be able to run. Mac OS X 10.2 was a paid upgrade so there was some value in ensuring that programs compiled on 10.2 could by default still run on 10.1, and so on PowerPC Mac OS X versions 10.1, 10.2, 10.3, and 10.4 Apple set the default deployment target to 10.1. This was apparently too old for something gcl was doing so you set the deployment target to 10.2 in h/powerpc-macosx.defs.

When Intel Macs were introduced h/powerpc-macosx.defs was copied to h/386-macosx.defs. Intel Macs were introduced during the lifetime of Mac OS X 10.4; they cannot run earlier versions of Mac OS X so it makes no sense to compile a program for Intel Mac OS X for a deployment target earlier than 10.4. The default value of the deployment target on Intel Mac OS X 10.4 is 10.4 so there is no need for you to set the deployment target on Intel Macs since it is already newer than what you require.

On Mac OS X 10.5 for all architectures, Apple changed to the strategy they still use today: the default deployment target is now the major OS version, e.g. when compiling on 10.5 the default deployment target is 10.5. PowerPC Macs cannot run Mac OS X versions greater than 10.5.x.

Fast-forwarding a decade, trying to compile for deployment target 10.2 on macOS 10.14 fails:


ld: library not found for -lgcc_s.10.4


I removed your 10.2 deployment target from gcl in MacPorts back in 2018 to fix this:

https://trac.macports.org/ticket/57312

Ryan Carsten Schmidt <ryandesign>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by camm (Posted a comment)
  • -email is unavailable- added by ryandesign (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follow 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2024-02-02 camm StatusNone Fixed
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-3230.
    Corresponding source code