Blame SOURCES/kyotocabinet-1.2.76-cflags.patch

a28464
Patch by Robert Scheck <robert@fedoraproject.org> for kyotocabinet >= 1.2.76 to ensure
a28464
that CFLAGS and CXXFLAGS do not include "-g0 -O2" or "-O0" at all as we need debug info
a28464
for the -debuginfo RPM packages. Additionally the patch removes "-rpath-link" as well.
a28464
a28464
--- kyotocabinet-1.2.76/configure			2012-05-24 13:31:45.000000000 +0200
a28464
+++ kyotocabinet-1.2.76/configure.cflags		2013-11-17 18:28:55.000000000 +0100
a28464
@@ -2109,8 +2109,8 @@
a28464
 MYPCFILES="kyotocabinet.pc"
a28464
 
a28464
 # Building flags
a28464
-MYCFLAGS="-Wall -ansi -pedantic -fPIC -fsigned-char -g0 -O2"
a28464
-MYCXXFLAGS="-Wall -fPIC -fsigned-char -g0 -O2"
a28464
+MYCFLAGS="-Wall -ansi -pedantic -fPIC -fsigned-char"
a28464
+MYCXXFLAGS="-Wall -fPIC -fsigned-char"
a28464
 MYCPPFLAGS="-I. -I\$(INCLUDEDIR) -I/usr/local/include"
a28464
 MYCPPFLAGS="$MYCPPFLAGS -DNDEBUG -D_GNU_SOURCE=1"
a28464
 MYCPPFLAGS="$MYCPPFLAGS -D_FILE_OFFSET_BITS=64 -D_REENTRANT -D__EXTENSIONS__"
a28464
@@ -2147,8 +2147,8 @@
a28464
 
a28464
 if test "$enable_debug" = "yes"
a28464
 then
a28464
-  MYCFLAGS="-Wall -ansi -pedantic -fPIC -fsigned-char -g -O0"
a28464
-  MYCXXFLAGS="-Wall -fPIC -fsigned-char -g -O0"
a28464
+  MYCFLAGS="-Wall -ansi -pedantic -fPIC -fsigned-char -g"
a28464
+  MYCXXFLAGS="-Wall -fPIC -fsigned-char -g"
a28464
   MYCPPFLAGS="$MYCPPFLAGS -UNDEBUG -D_KCDEBUG"
a28464
   is_static="yes"
a28464
   enables="$enables (debug)"
a28464
@@ -2178,8 +2178,8 @@
a28464
 
a28464
 if test "$enable_opt" = "no"
a28464
 then
a28464
-  MYCFLAGS="$MYCFLAGS -O0"
a28464
-  MYCXXFLAGS="$MYCXXFLAGS -O0"
a28464
+  MYCFLAGS="$MYCFLAGS"
a28464
+  MYCXXFLAGS="$MYCXXFLAGS"
a28464
   enables="$enables (no-opt)"
a28464
 fi
a28464
 
a28464
@@ -4538,7 +4538,6 @@
a28464
 # As-needed linking
a28464
 if uname | grep Linux >config.tmp
a28464
 then
a28464
-  MYLDFLAGS="$MYLDFLAGS -Wl,-rpath-link,.:/usr/local/lib:$MYLDLIBPATH"
a28464
   MYLDFLAGS="$MYLDFLAGS -Wl,--as-needed"
a28464
 else
a28464
   MYCMDLIBS="$MYCMDLIBS $LIBS"
a28464
--- kyotocabinet-1.2.76/configure.in			2012-05-24 13:31:42.000000000 +0200
a28464
+++ kyotocabinet-1.2.76/configure.in.cflags		2013-11-17 18:29:20.000000000 +0100
a28464
@@ -35,8 +35,8 @@
a28464
 MYPCFILES="kyotocabinet.pc"
a28464
 
a28464
 # Building flags
a28464
-MYCFLAGS="-Wall -ansi -pedantic -fPIC -fsigned-char -g0 -O2"
a28464
-MYCXXFLAGS="-Wall -fPIC -fsigned-char -g0 -O2"
a28464
+MYCFLAGS="-Wall -ansi -pedantic -fPIC -fsigned-char"
a28464
+MYCXXFLAGS="-Wall -fPIC -fsigned-char"
a28464
 MYCPPFLAGS="-I. -I\$(INCLUDEDIR) -I/usr/local/include"
a28464
 MYCPPFLAGS="$MYCPPFLAGS -DNDEBUG -D_GNU_SOURCE=1"
a28464
 MYCPPFLAGS="$MYCPPFLAGS -D_FILE_OFFSET_BITS=64 -D_REENTRANT -D__EXTENSIONS__"
a28464
@@ -70,8 +70,8 @@
a28464
   AC_HELP_STRING([--enable-debug], [build for debugging]))
a28464
 if test "$enable_debug" = "yes"
a28464
 then
a28464
-  MYCFLAGS="-Wall -ansi -pedantic -fPIC -fsigned-char -g -O0"
a28464
-  MYCXXFLAGS="-Wall -fPIC -fsigned-char -g -O0"
a28464
+  MYCFLAGS="-Wall -ansi -pedantic -fPIC -fsigned-char -g"
a28464
+  MYCXXFLAGS="-Wall -fPIC -fsigned-char -g"
a28464
   MYCPPFLAGS="$MYCPPFLAGS -UNDEBUG -D_KCDEBUG"
a28464
   is_static="yes"
a28464
   enables="$enables (debug)"
a28464
@@ -95,8 +95,8 @@
a28464
   AC_HELP_STRING([--disable-opt], [build without optimization]))
a28464
 if test "$enable_opt" = "no"
a28464
 then
a28464
-  MYCFLAGS="$MYCFLAGS -O0"
a28464
-  MYCXXFLAGS="$MYCXXFLAGS -O0"
a28464
+  MYCFLAGS="$MYCFLAGS"
a28464
+  MYCXXFLAGS="$MYCXXFLAGS"
a28464
   enables="$enables (no-opt)"
a28464
 fi
a28464
 
a28464
@@ -302,7 +302,6 @@
a28464
 # As-needed linking
a28464
 if uname | grep Linux >config.tmp
a28464
 then
a28464
-  MYLDFLAGS="$MYLDFLAGS -Wl,-rpath-link,.:/usr/local/lib:$MYLDLIBPATH"
a28464
   MYLDFLAGS="$MYLDFLAGS -Wl,--as-needed"
a28464
 else
a28464
   MYCMDLIBS="$MYCMDLIBS $LIBS"