summary refs log tree commit diff
path: root/pkgs/development/interpreters/lua-5
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2021-05-15 14:40:26 +0000
committerJonathan Ringer <jonringer@users.noreply.github.com>2021-05-15 09:33:46 -0700
commit665732d8779f7edbbc05f7e2428da4f40abcc3a8 (patch)
tree2f29b4955427de93d56c30c0ee04aaf164c6ce04 /pkgs/development/interpreters/lua-5
parent1758c0ac6531a6840ed78769022fd63765d713e1 (diff)
downloadnixpkgs-665732d8779f7edbbc05f7e2428da4f40abcc3a8.tar
nixpkgs-665732d8779f7edbbc05f7e2428da4f40abcc3a8.tar.gz
nixpkgs-665732d8779f7edbbc05f7e2428da4f40abcc3a8.tar.bz2
nixpkgs-665732d8779f7edbbc05f7e2428da4f40abcc3a8.tar.lz
nixpkgs-665732d8779f7edbbc05f7e2428da4f40abcc3a8.tar.xz
nixpkgs-665732d8779f7edbbc05f7e2428da4f40abcc3a8.tar.zst
nixpkgs-665732d8779f7edbbc05f7e2428da4f40abcc3a8.zip
lua: fix linkage
This fixes a couple of problems:

 * Lua 5.1 doesn't have SYSLIBS, so wasn't being linked with any
   libraries.

 * SYSLIBS doesn't include -lm, so we had to add that manually to
   pkgconfig.  LIBS includes -lm, so we don't need that hack any more.
Diffstat (limited to 'pkgs/development/interpreters/lua-5')
-rw-r--r--pkgs/development/interpreters/lua-5/interpreter.nix2
-rw-r--r--pkgs/development/interpreters/lua-5/lua-dso.make2
2 files changed, 2 insertions, 2 deletions
diff --git a/pkgs/development/interpreters/lua-5/interpreter.nix b/pkgs/development/interpreters/lua-5/interpreter.nix
index 506f9ca7207..fd8c47d751b 100644
--- a/pkgs/development/interpreters/lua-5/interpreter.nix
+++ b/pkgs/development/interpreters/lua-5/interpreter.nix
@@ -93,7 +93,7 @@ self = stdenv.mkDerivation rec {
     Description: An Extensible Extension Language
     Version: ${version}
     Requires:
-    Libs: -L$out/lib -llua -lm
+    Libs: -L$out/lib -llua
     Cflags: -I$out/include
     EOF
     ln -s "$out/lib/pkgconfig/lua.pc" "$out/lib/pkgconfig/lua-${luaversion}.pc"
diff --git a/pkgs/development/interpreters/lua-5/lua-dso.make b/pkgs/development/interpreters/lua-5/lua-dso.make
index 11ac71fd819..19c57685677 100644
--- a/pkgs/development/interpreters/lua-5/lua-dso.make
+++ b/pkgs/development/interpreters/lua-5/lua-dso.make
@@ -1,4 +1,4 @@
 $(LUA_SO): $(CORE_O) $(LIB_O)
-	$(CC) -shared $(SYSLIBS) -Wl,-soname,$(LUA_SO).$(V) -o $@.$(R) $? $(MYLDFLAGS)
+	$(CC) -shared $(LIBS) -Wl,-soname,$(LUA_SO).$(V) -o $@.$(R) $? $(MYLDFLAGS)
 	ln -sf $(LUA_SO).$(R) $(LUA_SO).$(V)
 	ln -sf $(LUA_SO).$(R) $(LUA_SO)