From fc1a2168a192bde621f612a35aeb0566467f9c63 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20W=C3=A4ckerlin?= Date: Thu, 30 Jul 2015 08:13:50 +0000 Subject: [PATCH] enable rpm build --- ChangeLog | 5 +++++ ax_init_standard_project.m4 | 43 ++++++++++++++++++++----------------- bootstrap.sh | 35 +++++++++++++++--------------- libpcscxx.spec.in | 29 ++++++++++++------------- 4 files changed, 60 insertions(+), 52 deletions(-) diff --git a/ChangeLog b/ChangeLog index 3ac9465..46bb468 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2015-07-27 08:35 marc + + * ChangeLog, ax_check_qt.m4, ax_init_standard_project.m4, + bootstrap.sh: better check for header + 2015-07-27 06:33 marc * configure.ac: remove test output diff --git a/ax_init_standard_project.m4 b/ax_init_standard_project.m4 index 1e30e9e..03988e1 100644 --- a/ax_init_standard_project.m4 +++ b/ax_init_standard_project.m4 @@ -3,45 +3,46 @@ ## 1 2 3 4 5 6 7 8 ## 45678901234567890123456789012345678901234567890123456789012345678901234567890 +# m4_esyscmd_s does not exist on centos 5 and 6 +m4_define([mrw_esyscmd_s], [m4_normalize(m4_esyscmd([$1]))]) + # define least version number from subversion's revision number: # it is taken modulo 256 due to a bug on Apple's MacOSX -m4_define(x_least, m4_esyscmd_s( +m4_define(x_least, mrw_esyscmd_s([ SVN_REVISION="ERROR-UNDEFINED-REVISION-to-be-built-in-subdirectory-of-svn-checkout" for path in . .. ../..; do if svn info $path 2>&1 > /dev/null; then SVN_REVISION=$(LANG= svn info $path | sed -n 's/Last Changed Rev: //p') - (cd $path && svn2cl) break; fi done # Mac does not support LEAST > 255 echo $ECHO_N $(($SVN_REVISION%256)) -)) +])) # define version number from subversion's revision number: # it is taken modulo 256 due to a bug on Apple's MacOSX # add to x_minor if revision number is > 256 -m4_define(x_minor_fixed, m4_esyscmd_s( +m4_define(x_minor_fixed, mrw_esyscmd_s([ SVN_REVISION="ERROR-UNDEFINED-REVISION-to-be-built-in-subdirectory-of-svn-checkout" for path in . .. ../..; do if svn info $path 2>&1 > /dev/null; then SVN_REVISION=$(LANG= svn info $path | sed -n 's/Last Changed Rev: //p') - (cd $path && svn2cl) break; fi done # Mac does not support LEAST > 255 echo $ECHO_N $((x_minor+$SVN_REVISION/256)) -)) +])) # setup version number -m4_define(x_version, m4_esyscmd_s( +m4_define(x_version, mrw_esyscmd_s([ echo $ECHO_N x_major.x_minor_fixed.x_least -)) +])) ## bugreport mail address is taken from in first line of AUTHORS -m4_define(x_bugreport, m4_esyscmd_s( +m4_define(x_bugreport, mrw_esyscmd_s([ head -1 AUTHORS | \ sed -n 's,.*<\([-_.a-z0-9A-Z]*@[-_.a-z0-9A-Z]*\)>.*,\1,gp' -)) +])) m4_include(ax_check_qt.m4) @@ -116,7 +117,7 @@ AC_DEFUN([AX_INIT_STANDARD_PROJECT], [ esac AM_CONDITIONAL(MINGW, test "$MINGW" = "yes") AM_CONDITIONAL(MAC, test "$MAC" = "yes") - AM_CPPFLAGS+=" '-DMAKE_STRING(X)=\#X' '-DNAMESPACE=${PACKAGE_NAME//-/_}'" + AM_CPPFLAGS+=" '-DMAKE_STRING(X)=\#X' '-DNAMESPACE=${PACKAGE_TARNAME//[^a-zA-Z0-9]/_}'" AX_SUBST(NUMBERS) AX_SUBST(HOME) README=$(tail -n +3 README) @@ -164,7 +165,6 @@ AC_DEFUN([AX_INIT_STANDARD_PROJECT], [ test -f makefile.in && cat >> makefile.in <> makefile.in <