From 2f119f29e3597e495dda6f0871508c4e6fb6f2f7 Mon Sep 17 00:00:00 2001
From: Jeremy Soller <jeremy@system76.com>
Date: Mon, 7 Jan 2019 19:09:51 -0700
Subject: [PATCH] Remove unnecessary -lm

---
 bin/x86_64-unknown-redox-llvm-config | 2 +-
 recipes/cairodemo/recipe.sh          | 2 +-
 recipes/newlibtest/recipe.sh         | 2 +-
 recipes/perl/recipe.sh               | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/bin/x86_64-unknown-redox-llvm-config b/bin/x86_64-unknown-redox-llvm-config
index 766e85548..642e9e52d 100755
--- a/bin/x86_64-unknown-redox-llvm-config
+++ b/bin/x86_64-unknown-redox-llvm-config
@@ -111,7 +111,7 @@ elif args == ["--ldflags"]:
 elif args == ["--libdir"]:
     print(prefix + "/lib")
 elif args == ["--system-libs"]:
-    print("-lpthread -lm")
+    print("")
 elif args == ["--targets-built"]:
     print("X86")
 elif args[0] == "--libs":
diff --git a/recipes/cairodemo/recipe.sh b/recipes/cairodemo/recipe.sh
index ff3125fb4..c720d9e51 100755
--- a/recipes/cairodemo/recipe.sh
+++ b/recipes/cairodemo/recipe.sh
@@ -21,7 +21,7 @@ function recipe_build {
     export LDFLAGS="-L$sysroot/lib"
     export CPPFLAGS="-I$sysroot/include"
     set -x
-    "${CXX}" -I "$sysroot/include" -L "$sysroot/lib" cairodemo.c -o cairodemo -lorbital -lcairo -lpixman-1 -lfreetype -lpng -lz -lm
+    "${CXX}" -I "$sysroot/include" -L "$sysroot/lib" cairodemo.c -o cairodemo -lorbital -lcairo -lpixman-1 -lfreetype -lpng -lz
     set +x
     skip=1
 }
diff --git a/recipes/newlibtest/recipe.sh b/recipes/newlibtest/recipe.sh
index 9dac27fee..d1d549d9d 100644
--- a/recipes/newlibtest/recipe.sh
+++ b/recipes/newlibtest/recipe.sh
@@ -15,7 +15,7 @@ function recipe_build {
     sysroot="$(realpath ../sysroot)"
     export CFLAGS="-static -nostdinc -I $sysroot/include -I /usr/lib/gcc/x86_64-unknown-redox/7.0.1/include/ -nostdlib -L $sysroot/lib"
     export CRT="$sysroot/lib/crt0.o"
-    export CLIBS="-lc -lm"
+    export CLIBS="-lc"
     make all -j"$(nproc)"
     skip=1
 }
diff --git a/recipes/perl/recipe.sh b/recipes/perl/recipe.sh
index d2d41986c..0d3f6f102 100644
--- a/recipes/perl/recipe.sh
+++ b/recipes/perl/recipe.sh
@@ -22,7 +22,7 @@ function recipe_build {
     sed -i "s/^#define Netdb_name_t.*/#define Netdb_name_t const char*/" config.h # XXX
     sed -i 's/#define Strerror(e).*$/#define Strerror(e) strerror(e)/' config.h #
     echo "#define HAS_VPRINTF" >> config.h
-    make LIBS=-lm -j"$(nproc)"
+    make -j"$(nproc)"
     skip=1
 }
 
-- 
GitLab