diff options
author | Juan Pablo Ugarte <juanpablougarte@gmail.com> | 2012-12-03 17:45:38 -0300 |
---|---|---|
committer | Juan Pablo Ugarte <juanpablougarte@gmail.com> | 2012-12-03 20:02:09 -0300 |
commit | e33751efb94410693e5ff5fa014192af230ddfac (patch) | |
tree | 1e030f2c46ad411bb5186b2cdaf675c802ec0933 | |
parent | 29870803a61fb0210035a4ec509339c74d134a34 (diff) | |
download | glade-e33751efb94410693e5ff5fa014192af230ddfac.tar.gz |
Ported build for mingw to 3.8 branch
-rw-r--r-- | build/mingw-w64/glade.nsi.in | 13 | ||||
-rw-r--r-- | build/mingw-w64/nsis_make_installer.sh | 31 |
2 files changed, 20 insertions, 24 deletions
diff --git a/build/mingw-w64/glade.nsi.in b/build/mingw-w64/glade.nsi.in index 99526b52..f5ff11d4 100644 --- a/build/mingw-w64/glade.nsi.in +++ b/build/mingw-w64/glade.nsi.in @@ -3,7 +3,7 @@ !include "FileFunc.nsh" ;General -!define APPNAME "Glade Interface Designer" +!define APPNAME "Glade Interface Designer Gtk+ 2" !define COMPANYNAME "GNOME Foundation" !define VERSIONMAJOR @GLADE_MAJOR_VERSION@ @@ -26,7 +26,7 @@ InstallDir "$LOCALAPPDATA\${COMPANYNAME}\${APPNAME}" RequestExecutionLevel user ;Interface Settings -!define MUI_ICON "glade.ico" +!define MUI_ICON "glade-3.ico" !define MUI_ABORTWARNING ;Pages @@ -71,22 +71,21 @@ FunctionEnd Section "Install" SetOutPath "$INSTDIR" file /r bin - file /r etc !include install_files.nsh - file glade.ico + file glade-3.ico ;Create uninstaller WriteUninstaller "$INSTDIR\Uninstall.exe" ;Create shortcuts createDirectory "$SMPROGRAMS\${COMPANYNAME}" - createShortCut "$SMPROGRAMS\${COMPANYNAME}\${APPNAME}.lnk" "$INSTDIR\bin\glade.exe" "" "$INSTDIR\glade.ico" + createShortCut "$SMPROGRAMS\${COMPANYNAME}\${APPNAME}.lnk" "$INSTDIR\bin\glade-3.exe" "" "$INSTDIR\glade-3.ico" ; Registry information for add/remove programs WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "DisplayName" "${COMPANYNAME} - ${APPNAME}" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "UninstallString" "$INSTDIR\uninstall.exe" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "QuietUninstallString" "$INSTDIR\uninstall.exe /S" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "InstallLocation" "$INSTDIR" - WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "DisplayIcon" "$\"$INSTDIR\glade.ico$\"" + WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "DisplayIcon" "$\"$INSTDIR\glade-3.ico$\"" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "Publisher" "$\"${COMPANYNAME}$\"" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "HelpLink" "$\"${HELPURL}$\"" WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${COMPANYNAME} ${APPNAME}" "URLUpdateInfo" "$\"${UPDATEURL}$\"" @@ -107,7 +106,7 @@ Section "Uninstall" rmDir "$SMPROGRAMS\${COMPANYNAME}" ; Remove files - delete "$INSTDIR\glade.ico" + delete "$INSTDIR\glade-3.ico" !include uninstall_files.nsh ; Always delete uninstaller as the last action diff --git a/build/mingw-w64/nsis_make_installer.sh b/build/mingw-w64/nsis_make_installer.sh index 41536ba9..1fc8db78 100644 --- a/build/mingw-w64/nsis_make_installer.sh +++ b/build/mingw-w64/nsis_make_installer.sh @@ -54,7 +54,7 @@ case $1 in ;; make) DEVELOPER="false" - EXCLUDE_FILES="-o -name *.dll.a -o -name *.la" + EXCLUDE_FILES="( -path lib/pkgconfig -o -name *.dll.a -o -name *.la ) -prune" INCLUDE_DIR= ;; *) @@ -90,28 +90,27 @@ if test ! -e download-mingw-rpm.py; then fi if test ! -d $MINGW_ROOT; then - python3 download-mingw-rpm.py --deps gtk3-devel libxml2-devel + python3 download-mingw-rpm.py --deps gtk2-devel libxml2-devel mv $MINGW_ROOT_BIN $MINGW_ROOT fi -if test x"$DEVELOPER"=xfalse -a ! -d $MINGW_ROOT_BIN; then - python3 download-mingw-rpm.py --deps gtk3 hicolor-icon-theme +if test $DEVELOPER = "false" -a ! -d $MINGW_ROOT_BIN; then + python3 download-mingw-rpm.py --deps gtk2 hicolor-icon-theme fi -if test ! -e $MINGW_ROOT_BIN/bin/glade.exe; then +if test ! -e $MINGW_ROOT_BIN/bin/glade-3.exe; then cd $ROOT && ./autogen.sh --prefix=$MINGW_ROOT_BIN $CONFIGURE_ARGS && make && make install # rename executables names -if test -e $MINGW_ROOT_BIN/bin/i686-w64-mingw32-glade.exe; then - mv $MINGW_ROOT_BIN/bin/i686-w64-mingw32-glade.exe $MINGW_ROOT_BIN/bin/glade.exe - mv $MINGW_ROOT_BIN/bin/i686-w64-mingw32-glade-previewer.exe $MINGW_ROOT_BIN/bin/glade-previewer.exe +if test -e $MINGW_ROOT_BIN/bin/i686-w64-mingw32-glade-3.exe; then + mv $MINGW_ROOT_BIN/bin/i686-w64-mingw32-glade-3.exe $MINGW_ROOT_BIN/bin/glade-3.exe fi fi #copy files to installer directory -cp $ROOT/build/mingw-w64/glade.nsi $ROOT/data/icons/glade.ico $MINGW_ROOT_BIN +cp $ROOT/build/mingw-w64/glade.nsi $ROOT/data/icons/glade-3.ico $MINGW_ROOT_BIN #change to installer directory cd $MINGW_ROOT_BIN @@ -143,26 +142,24 @@ EOF cat $ROOT/COPYING.GPL >> COPYING fi -# Update schemas just in case -glib-compile-schemas $MINGW_ROOT_BIN/share/glib-2.0/schemas +if test $DEVELOPER = "true"; then -if test x"$DEVELOPER"=xtrue; then cat > install_files.nsh << EOF - file /r /x locale lib - file /r /x locale share + file /r lib + file /r share file /r include EOF else cat > install_files.nsh << EOF - file /r /x locale /x pkgconfig /x *.dll.a /x *.la lib - file /r /x locale share + file /r /x pkgconfig /x *.dll.a /x *.la lib + file /r share EOF fi # Create a list of files to delete in the uninstaller # Note that we have to reverse the list to remove the directories once they are empty find bin etc lib share $INCLUDE_DIR \ - \( -path share/locale -o -path lib/locale -o -path lib/pkgconfig $EXCLUDE_FILES \) -prune \ + $EXCLUDE_FILES \ -o -type f -printf "delete \"\$INSTDIR\\\%p\"\n" -or -type d -printf "rmDir \"\$INSTDIR\\\%p\"\n" \ | sed 'y/\//\\/' | tac > uninstall_files.nsh |