[MacPorts] #58895: OpenBLAS @0.3.7 +native build failure: ld: library not found for -lSystem

MacPorts noreply at macports.org
Thu Aug 29 01:33:03 UTC 2019


#58895: OpenBLAS @0.3.7 +native build failure: ld: library not found for -lSystem
-----------------------+-------------------------
  Reporter:  prbuen    |      Owner:  NicosPavlov
      Type:  defect    |     Status:  assigned
  Priority:  Normal    |  Milestone:
 Component:  ports     |    Version:
Resolution:            |   Keywords:
      Port:  OpenBLAS  |
-----------------------+-------------------------

Comment (by kencu):

 I think you need to check out `gfortran` here and see where it is going
 wrong. Try to compile a very simple fortran program, `hello.f`:
 {{{
        program hello
           print *, "Hello World!"
        end program hello
 }}}

 be careful, fortan for me was a bit touchy. There are tabs at the start of
 each line, or it doesn't compile. I know nothing about fortran coding, but
 I do know compilers now.

 Then compile it with:
 {{{
 /opt/local/bin/gfortran-mp-9 -v -o hello hello.f
 }}}
 and try to run it if it compiles
 {{{
 ./hello
 }}}

 I get this, with lots of debug info, on 10.6.8 with gcc8:
 {{{
 $ /opt/local/bin/gfortran-mp-8 -v -o hello hello.f
 Driving: /opt/local/bin/gfortran-mp-8 -v -o hello hello.f -mmacosx-
 version-min=10.6.0 -asm_macosx_version_min=10.6 -l gfortran -shared-libgcc
 Using built-in specs.
 COLLECT_GCC=/opt/local/bin/gfortran-mp-8
 COLLECT_LTO_WRAPPER=/opt/local/libexec/gcc/x86_64-apple-darwin10/8.3.0
 /lto-wrapper
 Target: x86_64-apple-darwin10
 Configured with:
 /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_lang_gcc8/gcc8/work/gcc-8.3.0/configure
 --prefix=/opt/local --build=x86_64-apple-darwin10 --enable-
 languages=c,c++,objc,obj-c++,lto,fortran --libdir=/opt/local/lib/gcc8
 --includedir=/opt/local/include/gcc8 --infodir=/opt/local/share/info
 --mandir=/opt/local/share/man --datarootdir=/opt/local/share/gcc-8 --with-
 local-prefix=/opt/local --with-system-zlib --disable-nls --program-
 suffix=-mp-8 --with-gxx-include-dir=/opt/local/include/gcc8/c++/ --with-
 gmp=/opt/local --with-mpfr=/opt/local --with-mpc=/opt/local --with-
 isl=/opt/local --enable-stage1-checking --disable-multilib --enable-lto
 --enable-libstdcxx-time --with-build-config=bootstrap-debug --with-
 as=/opt/local/bin/as --with-ld=/opt/local/bin/ld --with-
 ar=/opt/local/bin/ar --with-bugurl=https://trac.macports.org/newticket
 --disable-tls --with-pkgversion='MacPorts gcc8 8.3.0_4'
 Thread model: posix
 gcc version 8.3.0 (MacPorts gcc8 8.3.0_4)
 COLLECT_GCC_OPTIONS='-v' '-o' 'hello' '-mmacosx-version-min=10.6.0'
 '-asm_macosx_version_min=10.6' '-shared-libgcc' '-mtune=core2'
  /opt/local/libexec/gcc/x86_64-apple-darwin10/8.3.0/f951 hello.f -ffixed-
 form -fPIC -quiet -dumpbase hello.f -mmacosx-version-min=10.6.0
 -mtune=core2 -auxbase hello -version -fintrinsic-modules-path
 /opt/local/lib/gcc8/gcc/x86_64-apple-darwin10/8.3.0/finclude -o
 /var/folders/I0/I0fOotq3ErGZHYxrmmWiqU+++TI/-Tmp-//ccsx2s89.s
 GNU Fortran (MacPorts gcc8 8.3.0_4) version 8.3.0 (x86_64-apple-darwin10)
         compiled by GNU C version 8.3.0, GMP version 6.1.2, MPFR version
 4.0.2, MPC version 1.1.0, isl version isl-0.21-GMP

 GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
 GNU Fortran2008 (MacPorts gcc8 8.3.0_4) version 8.3.0 (x86_64-apple-
 darwin10)
         compiled by GNU C version 8.3.0, GMP version 6.1.2, MPFR version
 4.0.2, MPC version 1.1.0, isl version isl-0.21-GMP

 GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
 COLLECT_GCC_OPTIONS='-v' '-o' 'hello' '-mmacosx-version-min=10.6.0'
 '-shared-libgcc' '-mtune=core2'
  /opt/local/bin/as -arch x86_64 -v -force_cpusubtype_ALL -mmacosx-version-
 min=10.6 -o /var/folders/I0/I0fOotq3ErGZHYxrmmWiqU+++TI/-Tmp-//cc9e8og5.o
 /var/folders/I0/I0fOotq3ErGZHYxrmmWiqU+++TI/-Tmp-//ccsx2s89.s
 clang version 8.0.0 (tags/RELEASE_800/final)
 Target: x86_64-apple-darwin10.8.0
 Thread model: posix
 InstalledDir: /opt/local/libexec/llvm-8.0/bin
  "/opt/local/libexec/llvm-8.0/bin/clang" -cc1as -triple x86_64-apple-
 macosx10.6.0 -filetype obj -main-file-name ccsx2s89.s -target-cpu core2
 -fdebug-compilation-dir /Users/cunningh -dwarf-debug-producer clang
 version 8.0.0 (tags/RELEASE_800/final) -dwarf-version=2 -mrelocation-model
 pic -o /var/folders/I0/I0fOotq3ErGZHYxrmmWiqU+++TI/-Tmp-//cc9e8og5.o
 /var/folders/I0/I0fOotq3ErGZHYxrmmWiqU+++TI/-Tmp-//ccsx2s89.s
 Reading specs from /opt/local/lib/gcc8/gcc/x86_64-apple-
 darwin10/8.3.0/../../../libgfortran.spec
 rename spec lib to liborig
 COLLECT_GCC_OPTIONS='-v' '-o' 'hello' '-mmacosx-version-min=10.6.0'
 '-shared-libgcc' '-mtune=core2'
 COMPILER_PATH=/opt/local/libexec/gcc/x86_64-apple-
 darwin10/8.3.0/:/opt/local/libexec/gcc/x86_64-apple-
 darwin10/8.3.0/:/opt/local/libexec/gcc/x86_64-apple-
 darwin10/:/opt/local/lib/gcc8/gcc/x86_64-apple-
 darwin10/8.3.0/:/opt/local/lib/gcc8/gcc/x86_64-apple-darwin10/
 LIBRARY_PATH=/opt/local/lib/gcc8/gcc/x86_64-apple-
 darwin10/8.3.0/:/opt/local/lib/gcc8/gcc/x86_64-apple-
 darwin10/8.3.0/../../../
 COLLECT_GCC_OPTIONS='-v' '-o' 'hello' '-mmacosx-version-min=10.6.0'
 '-shared-libgcc' '-mtune=core2'
  /opt/local/libexec/gcc/x86_64-apple-darwin10/8.3.0/collect2 -dynamic
 -arch x86_64 -macosx_version_min 10.6.0 -weak_reference_mismatches non-
 weak -o hello -lcrt1.10.6.o -L/opt/local/lib/gcc8/gcc/x86_64-apple-
 darwin10/8.3.0 -L/opt/local/lib/gcc8/gcc/x86_64-apple-
 darwin10/8.3.0/../../..
 /var/folders/I0/I0fOotq3ErGZHYxrmmWiqU+++TI/-Tmp-//cc9e8og5.o -lgfortran
 -no_compact_unwind -lSystem -lgcc_ext.10.5 -lgcc -lquadmath -lm
 -lgcc_ext.10.5 -lgcc -lSystem -v
 collect2 version 8.3.0
 /opt/local/bin/ld -dynamic -arch x86_64 -macosx_version_min 10.6.0
 -weak_reference_mismatches non-weak -o hello -lcrt1.10.6.o
 -L/opt/local/lib/gcc8/gcc/x86_64-apple-darwin10/8.3.0
 -L/opt/local/lib/gcc8/gcc/x86_64-apple-darwin10/8.3.0/../../..
 /var/folders/I0/I0fOotq3ErGZHYxrmmWiqU+++TI/-Tmp-//cc9e8og5.o -lgfortran
 -no_compact_unwind -lSystem -lgcc_ext.10.5 -lgcc -lquadmath -lm
 -lgcc_ext.10.5 -lgcc -lSystem -v
 @(#)PROGRAM:ld  PROJECT:ld64-274.2
 configured to support archs: i386 x86_64 x86_64h armv6 armv7 armv7s armv7m
 armv7k arm64 (tvOS)
 Library search paths:
         /opt/local/lib/gcc8/gcc/x86_64-apple-darwin10/8.3.0
         /opt/local/lib/gcc8
         /usr/lib
 Framework search paths:
         /Library/Frameworks/
         /System/Library/Frameworks/
  /opt/local/bin/nm -n
 /var/folders/I0/I0fOotq3ErGZHYxrmmWiqU+++TI/-Tmp-//cc9e8og5.o
 }}}

 And from this, you should see where `gfortan` is going wrong.

 For now, I'm sticking with my "buildbot builds it differently than your
 system" theory, but paste back your errors.

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


More information about the macports-tickets mailing list