[Pkg-privacy-commits] [pidgin-otr] 14/21: Update mingw32 cross-compile instructions

Intrigeri intrigeri at moszumanska.debian.org
Thu Mar 10 21:03:15 UTC 2016


This is an automated email from the git hooks/post-receive script.

intrigeri pushed a commit to branch master
in repository pidgin-otr.

commit ca28747069468c01ac0a1efc58cdad6485d101a6
Author: Ian Goldberg <iang at cs.uwaterloo.ca>
Date:   Sun Mar 6 11:46:12 2016 -0500

    Update mingw32 cross-compile instructions
    
    The INSTALL.mingw file is now actually a script that can be passed to
    bash.  It will download and compile the dependencies, and then build the
    pidgin-otr NSIS installer and zip file.
    
    Note that the GTK and pidgin libraries are downloaded in Windows binary
    form (though their checksums are checked), and not built from source.
    
    This script is known to work on one particular Ubuntu 14.04 machine.  It
    would be cool if others could try it as well, and it would be super-cool
    if we could turn this into a deterministic build.
---
 ChangeLog     |  12 ++++
 INSTALL       |   3 +-
 INSTALL.mingw | 200 ++++++++++++++++++++++++++++++----------------------------
 3 files changed, 119 insertions(+), 96 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 38dfce7..fc40903 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2016-03-06
+
+	* INSTALL.mingw: The INSTALL.mingw file is now actually a script
+	that can be passed to bash.  It will download and compile the
+	dependencies, and then build the pidgin-otr NSIS installer and
+	zip file.  Note that the GTK and pidgin libraries are downloaded
+	in Windows binary form (though their checksums are checked), and
+	not built from source.  This script is known to work on one
+	particular Ubuntu 14.04 machine.  It would be cool if others
+	could try it as well, and it would be super-cool if we could
+	turn this into a deterministic build.
+
 2016-03-05
 
 	* README:
diff --git a/INSTALL b/INSTALL
index 996fdde..da463c9 100644
--- a/INSTALL
+++ b/INSTALL
@@ -51,7 +51,8 @@ Use the provided Makefile.mingw:
 
     make -f Makefile.mingw
 
-See INSTALL.mingw for a few hints.
+See INSTALL.mingw for a script to try to do everything for you,
+including all of the dependencies.
 
 INSTALLATION
 
diff --git a/INSTALL.mingw b/INSTALL.mingw
index b644871..d7d328c 100644
--- a/INSTALL.mingw
+++ b/INSTALL.mingw
@@ -1,146 +1,156 @@
-Here are some rough notes that might help you create a pidgin-otr Win32
-build on a Linux system with mingw32. These have been tested on Ubuntu
-12.04.
+# Here are some rough notes that might help you create a pidgin-otr Win32
+# build on a Linux system with mingw32. These have been tested on Ubuntu
+# 14.04.  In theory, you can just pipe this file to bash.
 
-tl;dr download and install for files before disconnecting from the internet:
+# You may want a clean mingw32 environment first:
+# sudo apt-get purge mingw32 mingw32-runtime mingw32-binutils
+# sudo rm -rf /usr/i586-mingw32msvc
+sudo apt-get install mingw32 nsis
+
+mkdir pidgin-otr-win32
+cd pidgin-otr-win32
 
  wget -c  http://ftp.gnu.org/pub/gnu/libiconv/libiconv-1.14.tar.gz \
-          http://ftp.gnu.org/pub/gnu/gettext/gettext-0.19.3.tar.xz \
-          ftp://ftp.gnupg.org/gcrypt/libgpg-error/libgpg-error-1.17.tar.gz \
-          https://otr.cypherpunks.ca/gpg-error-1.17-mingw.diff \
-          ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-1.5.4.tar.gz \
-          https://otr.cypherpunks.ca/gcrypt-1.5.4-mingw.diff \
+          http://ftp.gnu.org/pub/gnu/gettext/gettext-0.19.3.tar.gz \
+          ftp://ftp.gnupg.org/gcrypt/libgpg-error/libgpg-error-1.20.tar.gz \
+          https://otr.cypherpunks.ca/gpg-error-1.20-mingw.diff \
+          ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-1.6.5.tar.gz \
+          https://otr.cypherpunks.ca/gcrypt-1.6.5-mingw.diff \
           http://ftp.gnome.org/pub/gnome/binaries/win32/gtk+/2.24/gtk+-bundle_2.24.10-20120208_win32.zip \
-          http://sourceforge.net/projects/pidgin/files/Pidgin/2.10.9/pidgin-2.10.9.tar.bz2 \
-          http://sourceforge.net/projects/pidgin/files/Pidgin/2.10.9/pidgin-2.10.9-win32-bin.zip \
-          https://otr.cypherpunks.ca/nsisunz.zip
-
- apt-get install mingw32 nsis
-
-The above files have the following SHA1 values:
-
-be7d67e50d72ff067b2c0291311bc283add36965  libiconv-1.14.tar.gz
-5c8e37c5275742b6acc1257e2df9b5d1874c12e3  gettext-0.19.3.tar.xz
-7c47e46a9b3af7fcca78f98ee71f36045bfc680c  libgpg-error-1.17.tar.gz
-b308288c9c277e9685eddf41f3cf7edf11d3821d  gpg-error-1.17-mingw.diff
-71e432e0ae8792076a40c6059667997250abbb9d  libgcrypt-1.5.4.tar.gz
-0c4396fecd2ca796ad167bf6af30d5e5038e7003  gcrypt-1.5.4-mingw.diff
-895072c22f5bfd4ac9054d48d62d6c8b2a487098  gtk+-bundle_2.24.10-20120208_win32.zip
-f3de8fd94dba1f4c98d5402a02430f9f323e665a  pidgin-2.10.9.tar.bz2
-23f330a2280e8f63e3b2c89752919cc3383886fa  pidgin-2.10.9-win32-bin.zip
-caeeb30321966279285228f9afa088c7f4cace84  nsisunz.zip
-
-
-Packages and their build instructions in the order they should be built.
-Good luck!
-
-mingw:
-  apt-get install mingw32
-
-
-libiconv-1.14:
-  wget http://ftp.gnu.org/pub/gnu/libiconv/libiconv-1.14.tar.gz
+          http://sourceforge.net/projects/pidgin/files/Pidgin/2.10.12/pidgin-2.10.12.tar.bz2 \
+          http://sourceforge.net/projects/pidgin/files/Pidgin/2.10.12/pidgin-2.10.12-win32-bin.zip \
+          https://otr.cypherpunks.ca/nsisunz.zip \
+	  https://otr.cypherpunks.ca/libotr-4.1.1.tar.gz
+
+# The above files have the following SHA256 values:
+
+diff <(sha256sum libiconv-1.14.tar.gz \
+	    gettext-0.19.3.tar.gz \
+	    libgpg-error-1.20.tar.gz \
+	    gpg-error-1.20-mingw.diff \
+	    libgcrypt-1.6.5.tar.gz \
+	    gcrypt-1.6.5-mingw.diff \
+	    gtk+-bundle_2.24.10-20120208_win32.zip \
+	    pidgin-2.10.12.tar.bz2 \
+	    pidgin-2.10.12-win32-bin.zip \
+	    nsisunz.zip \
+	    libotr-4.1.1.tar.gz) - <<EOD || exit 1
+72b24ded17d687193c3366d0ebe7cde1e6b18f0df8c55438ac95be39e8a30613  libiconv-1.14.tar.gz
+93952d505a3d3b1ec10c69d340c7d438b1f9c332710d583981c0608be3eeb3f6  gettext-0.19.3.tar.gz
+ccd00b4b115de3d2cd7f789f86d668b99bb2fe505d7a7edcff851ddd904ecd05  libgpg-error-1.20.tar.gz
+77e6ba99e10325b20d004c5b3290cdb21dbaddcbd54db893f44ed90216636c40  gpg-error-1.20-mingw.diff
+202bf109ccf2d614565c849f3e5687b94cde972167b35261e094252367627bc6  libgcrypt-1.6.5.tar.gz
+39311996df4aa735bd391262eb646bf53f4dad4eb259f512f8810377d63f6f7d  gcrypt-1.6.5-mingw.diff
+f5ce173f50690c2dc7fa91b9b5c80c7422cde3ee23610b53e0929557dd8ee67e  gtk+-bundle_2.24.10-20120208_win32.zip
+2c7523f0fefe89749c03b2b738ab9f7bd186da435be4762f1487eee31e77ffdd  pidgin-2.10.12.tar.bz2
+f1da4bb54d09a083e2130e60d874767c081923eb498e4a43d6418d25a4857ee8  pidgin-2.10.12-win32-bin.zip
+599029776df526def921ea178a6f66325b6f719772c38318e349a5c92a03afe9  nsisunz.zip
+8b3b182424251067a952fb4e6c7b95a21e644fbb27fbd5f8af2b2ed87ca419f5  libotr-4.1.1.tar.gz
+EOD
+
+
+# Packages and their build instructions in the order they should be built.
+# Good luck!
+
+# libiconv-1.14:
   tar xzvvf libiconv-1.14.tar.gz
   cd libiconv-1.14
   CFLAGS="-g -O2 -fwrapv -fno-strict-overflow"
   LDFLAGS="-pie"
   export CFLAGS LDFLAGS
   ./configure --enable-static --disable-shared --with-pic --host=i586-mingw32msvc --prefix=/usr/i586-mingw32msvc
-  make
-  sudo make install
+  make || exit 1
+  sudo make install || exit 1
+  cd ..
 
 
-gettext-0.19.3:
-  wget http://ftp.gnu.org/pub/gnu/gettext/gettext-0.19.3.tar.xz
-  tar xJvvf gettext-0.19.3.tar.xz
+# gettext-0.19.3:
+  tar xzvvf gettext-0.19.3.tar.gz
   cd gettext-0.19.3
   CFLAGS="-g -O2 -fwrapv -fno-strict-overflow"
   LDFLAGS="-pie"
   export CFLAGS LDFLAGS
   ./configure --enable-static --disable-shared --with-pic --host=i586-mingw32msvc --prefix=/usr/i586-mingw32msvc
-  make
-  sudo make install
+  make || exit 1
+  sudo make install || exit 1
+  cd ..
 
 
-libgpg-error-1.17:
-  wget ftp://ftp.gnupg.org/gcrypt/libgpg-error/libgpg-error-1.17.tar.gz
-  tar xzvvf libgpg-error-1.17.tar.gz
+# libgpg-error-1.20:
+  tar xzvvf libgpg-error-1.20.tar.gz
+  cd libgpg-error-1.20
   CFLAGS="-g -O2 -fstack-protector-all -Wstack-protector -fwrapv --param ssp-buffer-size=1 -fno-strict-overflow"
   LDFLAGS="-pie"
   export CFLAGS LDFLAGS
-  cd libgpg-error-1.17
-  patch -p0 < ../gpg-error-1.17-mingw.diff
+  patch -p0 < ../gpg-error-1.20-mingw.diff
   ./configure --enable-static --disable-shared --with-pic --host=i586-mingw32msvc --prefix=/usr/i586-mingw32msvc
   cp src/syscfg/lock-obj-pub.mingw32.h src/syscfg/lock-obj-pub.mingw32msvc.h
-  make
-  sudo make install
+  make || exit 1
+  sudo make install || exit 1
+  cd ..
 
-libgcrypt-1.5.4:
-  wget ftp://ftp.gnupg.org/gcrypt/libgcrypt/libgcrypt-1.5.4.tar.gz
-  tar xzvvf libgcrypt-1.5.4.tar.gz
-  cd libgcrypt-1.5.4
+# libgcrypt-1.6.5:
+  tar xzvvf libgcrypt-1.6.5.tar.gz
+  cd libgcrypt-1.6.5
   CFLAGS="-g -O2 -fstack-protector-all -Wstack-protector -fwrapv --param ssp-buffer-size=1 -fno-strict-overflow"
   LDFLAGS="-pie"
   export CFLAGS LDFLAGS
-  patch -p0 < ../gcrypt-1.5.4-mingw.diff
+  patch -p1 < ../gcrypt-1.6.5-mingw.diff
   w32root=/usr/i586-mingw32msvc ./autogen.sh --build-w32
-  make
-  sudo make install
+  make || exit 1
+  sudo make install || exit 1
+  cd ..
   
-nsis:
-  sudo apt-get install nsis
+# nsis:
   # Locate the "nsisunz" plugin (a google search for "nsisunz.zip" should be sufficient)
   # Extract the DLL to /usr/share/nsis/Plugins
   # (yes it's a DLL extension, but it will still work for GNU/Linux nsis)
-  wget -c https://otr.cypherpunks.ca/nsisunz.zip
   unzip nsisunz.zip
   sudo cp nsisunz/Release/nsisunz.dll /usr/share/nsis/Plugins/
 
 
-libotr-4.1.0:
-  autoreconf -s -i
+# libotr-4.1.1:
+  tar xzvvf libotr-4.1.1.tar.gz
+  cd libotr-4.1.1
   unset CFLAGS
   unset LDFLAGS
+  ./bootstrap
   ./configure --with-pic --host=i586-mingw32msvc \
         --prefix=/usr/i586-mingw32msvc \
         --enable-static --disable-shared \
         --with-libgcrypt-prefix=/usr/i586-mingw32msvc
-  make
-  sudo make install
-
-pidgin-otr:
-  # You will need: Pidgin source code distributable,
-  # Pidgin Win32 distributable, 
-  # and an "all-in-one bundle" of the GTK+ stack 2.14.7 or greater
-  # e.g., gtk+-bundle_2.24.10-20120208_win32.zip from 
-  # http://www.gtk.org/download/win32.php
+  make || exit 1
+  sudo make install || exit 1
+  cd ..
+
+# pidgin-otr:
   # In Makefile.mingw, specify the location of PIDGIN_HEADERS, PURPLE_HEADERS,
   # GTK_WIN32_BUNDLE, and PIDGIN_WIN32_LIBS
   # Ensure either pkg-config will correctly resolve all the dependencies for
   # glib-2.0 and gtk+-2.0. There is a README in the GTK+ bundle about this, or
   # uncomment (and perhaps revise) the hardcoded list of includes for GTK_HDRS
-  wget http://sourceforge.net/projects/pidgin/files/Pidgin/2.10.9/pidgin-2.10.9.tar.bz2
-  wget http://sourceforge.net/projects/pidgin/files/Pidgin/2.10.9/pidgin-2.10.9-win32-bin.zip
-  wget http://ftp.gnome.org/pub/gnome/binaries/win32/gtk+/2.24/gtk+-bundle_2.24.10-20120208_win32.zip
   sudo mkdir -p /usr/i586-mingw32msvc/misc/gtk_bundle
   sudo unzip -d /usr/i586-mingw32msvc/misc/gtk_bundle gtk+-bundle_2.24.10-20120208_win32.zip
-  unzip pidgin-2.10.9-win32-bin.zip
+  unzip pidgin-2.10.12-win32-bin.zip
   sudo mkdir -p /usr/i586-mingw32msvc/misc/pidgin_dlls
-  sudo mv pidgin-2.10.9-win32bin/*.dll /usr/i586-mingw32msvc/misc/pidgin_dlls/
-  tar xjvvf pidgin-2.10.9.tar.bz2
-  sudo mv pidgin-2.10.9/libpurple /usr/i586-mingw32msvc/include/
-  sudo mv pidgin-2.10.9/pidgin /usr/i586-mingw32msvc/include/
-  cd /path/to/pidgin-otr/
-  # Finally build pidgin-otr plugin
-  make -f Makefile.mingw
-  # This should now build the nsis installer
-  make -f Makefile.mingw installer
-  # This should now build the zipfile
-  make -f Makefile.mingw zip
-
-The pidgin-otr plugin will be created in the current working directory;
-inspect it with unzip:
-
-  unzip -l pidgin-otr-4.0.2.zip
-
-The installer will be created in packaging/windows/pidgin-otr-4.0.2.exe .
+  sudo mv pidgin-2.10.12-win32bin/*.dll /usr/i586-mingw32msvc/misc/pidgin_dlls/
+  tar xjvvf pidgin-2.10.12.tar.bz2
+  sudo mv pidgin-2.10.12/libpurple /usr/i586-mingw32msvc/include/
+  sudo mv pidgin-2.10.12/pidgin /usr/i586-mingw32msvc/include/
+  cd ..
+  # Build pidgin-otr plugin
+  make LIBOTRSRCDIR=pidgin-otr-win32/libotr-4.1.1 -f Makefile.mingw || exit 1
+  # This should build the nsis installer
+  rm -rf win32_export
+  make LIBOTRSRCDIR=pidgin-otr-win32/libotr-4.1.1 -f Makefile.mingw installer || exit 1
+  mv pidgin-otr-win32/packaging/windows/pidgin-otr-4.0.2.exe .
+  # This should build the zipfile
+  make LIBOTRSRCDIR=pidgin-otr-win32/libotr-4.1.1 -f Makefile.mingw zip || exit 1
+
+# The pidgin-otr plugin will be created in the current working directory;
+# inspect it with unzip:
+#
+#   unzip -l pidgin-otr-4.0.2.zip
+#
+# The installer will be moved (as above) into the current working
+# directory as well.

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/pidgin-otr.git



More information about the Pkg-privacy-commits mailing list