From 8edb10d31e2a7a0e393d845881549473f8518be6 Mon Sep 17 00:00:00 2001 From: Patrick Mahoney Date: Thu, 16 Oct 2014 14:40:25 -0500 Subject: talloc: Fix linker flags on darwin. Before this patch, building talloc on darwin (OS X 10.8.5) results in: gcc -dynamiclib -Wl,-search_paths_first -undefined error -o libtalloc.dylib.2.0.1 ./talloc.o ./libreplace/replace.o ./libreplace/snprintf.o ./libreplace/getpass.o ./libreplace/strptime.o -install_namelibtalloc.dylib.2 gcc: error: unrecognized command line option '-install_namelibtalloc.dylib.2' make: *** [libtalloc.dylib.2.0.1] Error 1 Setting SONAMEFLAG to either "-install_name " (note trailing space), or "-Wl,-install_name," results in a successful build. The latter seems more clear. --- pkgs/development/libraries/talloc/default.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pkgs') diff --git a/pkgs/development/libraries/talloc/default.nix b/pkgs/development/libraries/talloc/default.nix index 55ae69e6e643..a8975e29b4b3 100644 --- a/pkgs/development/libraries/talloc/default.nix +++ b/pkgs/development/libraries/talloc/default.nix @@ -12,7 +12,7 @@ stdenv.mkDerivation rec { # https://bugzilla.samba.org/show_bug.cgi?id=7000 postConfigure = if stdenv.isDarwin then '' - substituteInPlace "Makefile" --replace "SONAMEFLAG = #" "SONAMEFLAG = -install_name" + substituteInPlace "Makefile" --replace "SONAMEFLAG = #" "SONAMEFLAG = -Wl,-install_name," '' else ""; meta = { -- cgit 1.4.1