Describe the bug
I'm trying to build octaveFull from nixpkgs master on Darwin and am seeing the following error from libtool:
libtool: error(B: cannot find the library '' or unhandled argument 'DiskArbitration'(B
make[2]: *** [Makefile:14406: src/octave-svgconvert] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory '/private/var/folders/r_/05nj9pr95k51ps6_4qkhjqc00000gn/T/nix-build-octave-5.2.0.drv-0/octave-5.2.0'
make[1]: *** [Makefile:25976: all-recursive] Error 1
make[1]: Leaving directory '/private/var/folders/r_/05nj9pr95k51ps6_4qkhjqc00000gn/T/nix-build-octave-5.2.0.drv-0/octave-5.2.0'
make: *** [Makefile:9769: all] Error 2
note: keeping build directory '/private/var/folders/r_/05nj9pr95k51ps6_4qkhjqc00000gn/T/nix-build-octave-5.2.0.drv-0'
builder for '/nix/store/gj227i6aqzwjv2qq34kk0c0ykx41d1l1-octave-5.2.0.drv' failed with exit code 2
error: build of '/nix/store/gj227i6aqzwjv2qq34kk0c0ykx41d1l1-octave-5.2.0.drv' failed
This is due to the inclusion of '-framework' arguments in the .la files for Qt, e.g. lib/libQt5Core.la, which lib tool doesn't understand:
dependency_libs='-L/nix/store/4d0picrqabbvanz8w5ls4b5da9553zgh-icu4c-67.1/lib -L/nix/store/8mc3bj0a3ca8xh8hdb8aqfnkc8xrpszx-zlib-1.2.11/lib -L/nix/store/qgbmciwzn0sq6q562f8b1gs6bp1nc20w-libjpeg-turbo-2.0.4/lib -L/nix/store/rzhq65c2n9jpp5jv70fmhps1xz6807cl-harfbuzz-2.6.7/lib -L/nix/store/q662m1ga3knvysd38ivywkr877gvzb7c-openssl-1.1.1g/lib -framework DiskArbitration -framework IOKit'
This seems to be due to a longstanding conflict between qmake and libtool that I haven't found a resolution for:
I have a potential patch for pkgs/development/libraries/qt-5/hooks/fix-qmake-libtool.sh to remove these args from dependency_libs and move them to inherited_linker_flags which seems to resolve the issue for me. I'll post a PR for that. However it seems that this problem would affect other uses of Qt on Darwin using lib tool, so I wonder if there's some deeper problem with my own configuration that's causing me to hit this.
To Reproduce
Steps to reproduce the behavior:
nix-build -A pkgs.octaveFull on Darwin with nixpkgs master
Expected behavior
It should build without errors.
Notify maintainers
@idontgetoutmuch @doronbehar
Metadata
Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.
- system: `"x86_64-darwin"`
- host os: `Darwin 19.5.0, macOS `
- multi-user?: `no`
- sandbox: `no`
- version: `nix-env (Nix) 2.3.6`
- channels(...): `"nixpkgs-20.09pre239985.a332da8588a"`
- nixpkgs: `/Users/.../.nix-defexpr/channels/nixpkgs`
Maintainer information:
# a list of nixpkgs attributes affected by the problem
attribute:
# a list of nixos modules affected by the problem
module:
Describe the bug
I'm trying to build octaveFull from nixpkgs master on Darwin and am seeing the following error from libtool:
This is due to the inclusion of '-framework' arguments in the .la files for Qt, e.g.
lib/libQt5Core.la, which lib tool doesn't understand:This seems to be due to a longstanding conflict between qmake and libtool that I haven't found a resolution for:
I have a potential patch for
pkgs/development/libraries/qt-5/hooks/fix-qmake-libtool.shto remove these args from dependency_libs and move them toinherited_linker_flagswhich seems to resolve the issue for me. I'll post a PR for that. However it seems that this problem would affect other uses of Qt on Darwin using lib tool, so I wonder if there's some deeper problem with my own configuration that's causing me to hit this.To Reproduce
Steps to reproduce the behavior:
nix-build -A pkgs.octaveFullon Darwin with nixpkgs masterExpected behavior
It should build without errors.
Notify maintainers
@idontgetoutmuch @doronbehar
Metadata
Please run
nix-shell -p nix-info --run "nix-info -m"and paste the result.Maintainer information: