diff options
Diffstat (limited to 'pidgin/win32/nsis/generate_gtk_zip.sh')
-rwxr-xr-x | pidgin/win32/nsis/generate_gtk_zip.sh | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/pidgin/win32/nsis/generate_gtk_zip.sh b/pidgin/win32/nsis/generate_gtk_zip.sh index abe222781a..d57309f71d 100755 --- a/pidgin/win32/nsis/generate_gtk_zip.sh +++ b/pidgin/win32/nsis/generate_gtk_zip.sh @@ -3,8 +3,8 @@ PIDGIN_BASE=$1 -if [ ! -e $PIDGIN_BASE/ChangeLog.win32 ]; then - echo `basename $0` must must have the pidgin base dir specified as a parameter. +if [ ! -e $PIDGIN_BASE/ChangeLog ]; then + echo $(basename $0) must must have the pidgin base dir specified as a parameter. exit 1 fi @@ -42,12 +42,18 @@ echo Bundle Version $BUNDLE_VERSION > $CONTENTS_FILE function download_and_extract { URL=${1%%\ *} NAME=${1#*\ } - FILE=`basename $URL` + FILE=$(basename $URL) if [ ! -e $FILE ]; then echo Downloading $NAME - wget $URL + wget $URL || return 1 fi - unzip -q $FILE -d $INSTALL_DIR + EXTENSION=${FILE##*.} + #This is an OpenSuSE build service RPM + if [ $EXTENSION == 'rpm' ]; then + echo "Generating zip from $FILE" + FILE=$(../rpm2zip.sh $FILE) + fi + unzip -q $FILE -d $INSTALL_DIR || exit 1 echo "$NAME" >> $CONTENTS_FILE } @@ -63,9 +69,9 @@ echo gtk-theme-name = \"MS-Windows\" > $INSTALL_DIR/etc/gtk-2.0/gtkrc #Blow away translations that we don't have in Pidgin for LOCALE_DIR in $INSTALL_DIR/share/locale/* do - LOCALE=`basename $LOCALE_DIR` + LOCALE=$(basename $LOCALE_DIR) if [ ! -e $PIDGIN_BASE/po/$LOCALE.po ]; then - echo Remove $LOCALE translation as it is missing from Pidgin + echo Removing $LOCALE translation as it is missing from Pidgin rm -r $LOCALE_DIR fi done @@ -73,3 +79,5 @@ done #Generate zip file to be included in installer zip -9 -r ../gtk-runtime-$BUNDLE_VERSION.zip Gtk +exit 0 + |