From f287f0424a983b1f542aa2cf95ecb44810dbcfb3 Mon Sep 17 00:00:00 2001 From: dequis Date: Thu, 26 Jun 2014 05:07:11 -0300 Subject: Fix version in pkg-config file, also change bzr version format slightly Old bzr version format: bzr-1234 New bzr version format: 3.2.1-bzr-1234 Version spoofing with the BITLBEE_VERSION also changed slightly - it does not need quotes around the version number anymore for it to compile correctly. --- configure | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'configure') diff --git a/configure b/configure index e98d5a8b..3ac1680d 100755 --- a/configure +++ b/configure @@ -540,6 +540,7 @@ if [ ! -e doc/user-guide/help.txt ] && ! type xmlto > /dev/null 2> /dev/null; th echo 'Install xmlto if you want online help to work.' fi +REAL_BITLBEE_VERSION=`grep '^#define BITLBEE_VERSION ' $srcdir/bitlbee.h | sed 's/.*\"\(.*\)\".*/\1/'` echo if [ -z "$BITLBEE_VERSION" -a -d .bzr ] && type bzr > /dev/null 2> /dev/null; then nick=`bzr nick` @@ -550,14 +551,17 @@ if [ -z "$BITLBEE_VERSION" -a -d .bzr ] && type bzr > /dev/null 2> /dev/null; th fi rev=`bzr revno` echo 'Using bzr revision #'$rev' as version number' - BITLBEE_VERSION=\"bzr$nick-$rev\" + BITLBEE_VERSION=$REAL_BITLBEE_VERSION-bzr$nick-$rev fi if [ -n "$BITLBEE_VERSION" ]; then echo 'Spoofing version number: '$BITLBEE_VERSION echo '#undef BITLBEE_VERSION' >> config.h - echo '#define BITLBEE_VERSION '$BITLBEE_VERSION >> config.h + echo '#define BITLBEE_VERSION "'$BITLBEE_VERSION'"' >> config.h echo +else + # for pkg-config + BITLBEE_VERSION=$REAL_BITLBEE_VERSION fi if ! make helloworld > /dev/null 2>&1; then -- cgit v1.2.3