[MacPorts] #61513: gcc10 @10.2.0 gfortran-mp-10 ld warnings: dylib .. built for newer macOS version (11.0) than being linked (10.16)

MacPorts noreply at macports.org
Wed Nov 18 17:43:52 UTC 2020


#61513: gcc10 @10.2.0 gfortran-mp-10 ld warnings: dylib .. built for newer macOS
version (11.0) than being linked (10.16)
----------------------+--------------------
  Reporter:  pmaxted  |      Owner:  (none)
      Type:  defect   |     Status:  new
  Priority:  Normal   |  Milestone:
 Component:  ports    |    Version:  2.6.4
Resolution:           |   Keywords:  bigsur
      Port:  gcc10    |
----------------------+--------------------

Comment (by cjones051073):

 Replying to [comment:7 pmaxted]:
 > Replying to [comment:2 cjones051073]:
 > > Are you doing anything to explicitly force the use of 10.16 as the
 deployment target ?
 >
 >  Not deliberately - I don't have much experience with macports so I am
 not doing anything complicated.
 >
 >  The only complication I had when installing gcc was that I tried to
 install gcc9, but that failed, so I installed gcc10 instead,
 > Regards,
 >  -Pierre

 I cannot reproduce what you see. Running

 {{{
  > gfortran-mp-10 -v ./test.f90
 }}}

 does not generate any of the warnings you quote.

 Specifically I see

 {{{
 Driving: gfortran-mp-10 -v ./test.f90
 --sysroot=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk
 -mmacosx-version-min=11.0.0 -asm_macosx_version_min=11.0 -l gfortran
 -shared-libgcc
 <snip>
 /opt/local/bin/ld -syslibroot
 /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/
 -dynamic -arch x86_64 -macosx_version_min 11.0.0
 -weak_reference_mismatches non-weak -o a.out
 -L/opt/local/lib/gcc10/gcc/x86_64-apple-darwin20/10.2.0
 -L/opt/local/lib/gcc10/gcc/x86_64-apple-darwin20/10.2.0/../../..
 /var/folders/97/z7_b52957j36mhz075gflttr0000gn/T//ccyJcgHY.o -lgfortran
 -lSystem -lgcc_ext.10.5 -lgcc -lquadmath -lm -lgcc_ext.10.5 -lgcc -lSystem
 -no_compact_unwind -v
 }}}

 note 11.0.0 is set as the main macOSX version there, which is what I would
 expect as it should be the default.

 You on the other hand have

 {{{
 [macpflm2:~] pflm% /opt/local/bin/gfortran-mp-10 -v simple.f -o simple
 2       Driving: /opt/local/bin/gfortran-mp-10 -v simple.f -o simple
 -mmacosx-version-min=10.16.0 -asm_macosx_version_min=10.16 -l gfortran
 -shared-libgcc
 <snip>
 /opt/local/bin/ld -syslibroot
 /Library/Developer/CommandLineTools/SDKs/MacOSX11.0.sdk/ -dynamic -arch
 x86_64 -macosx_version_min 10.16.0 -weak_reference_mismatches non-weak -o
 simple -L/opt/local/lib/gcc10/gcc/x86_64-apple-darwin20/10.2.0
 -L/opt/local/lib/gcc10/gcc/x86_64-apple-darwin20/10.2.0/../../..
 /var/folders/dl/tc85r2_j2v94kqhby3hvz4n00000gn/T//ccazhqmk.o -lgfortran
 -lSystem -lgcc_ext.10.5 -lgcc -lquadmath -lm -lgcc_ext.10.5 -lgcc -lSystem
 -no_compact_unwind -v
 }}}

 So I am afraid but there has to be something specific to your environment
 that is forcing 10.16 to be the deployment target.

-- 
Ticket URL: <https://trac.macports.org/ticket/61513#comment:9>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list