gnucash-on-windows master: Multiple changes pushed

John Ralls jralls at code.gnucash.org
Sat Apr 23 14:08:23 EDT 2016


Updated	 via  https://github.com/Gnucash/gnucash-on-windows/commit/833d3c77 (commit)
	 via  https://github.com/Gnucash/gnucash-on-windows/commit/58aa9094 (commit)
	from  https://github.com/Gnucash/gnucash-on-windows/commit/d6568fe7 (commit)



commit 833d3c777e16b874d2b3ec446c9b7a89376c8390
Author: Rob Gowin <robgowin at gmail.com>
Date:   Sat Apr 23 09:25:36 2016 -0500

    Get correct path to config.h when building with CMake

diff --git a/dist-impl.sh b/dist-impl.sh
index 116bc3d..a41f13e 100755
--- a/dist-impl.sh
+++ b/dist-impl.sh
@@ -36,6 +36,7 @@ function dist_prepare() {
     _GC_WIN_REPOS_UDIR=`unix_path $GC_WIN_REPOS_DIR`
     _REPOS_UDIR=`unix_path $REPOS_DIR`
     _BUILD_UDIR=`unix_path $BUILD_DIR`
+    _GNUCASH_CMAKE_BUILD_UDIR=`unix_path $GNUCASH_CMAKE_BUILD_DIR`
     _DIST_UDIR=`unix_path $DIST_DIR`
     _MINGW_UDIR=`unix_path $MINGW_DIR`
     _INSTALL_UDIR=`unix_path $INSTALL_DIR`
@@ -260,6 +261,9 @@ function dist_gnucash() {
     AQBANKING_VERSION_H=${_AQBANKING_UDIR}/include/aqbanking5/aqbanking/version.h
     GWENHYWFAR_VERSION_H=${_GWENHYWFAR_UDIR}/include/gwenhywfar4/gwenhywfar/version.h
     GNUCASH_CONFIG_H=${_BUILD_UDIR}/config.h
+    if [ "$WITH_CMAKE" == "yes" ]; then
+        GNUCASH_CONFIG_H=${_GNUCASH_CMAKE_BUILD_UDIR}/src/config.h
+    fi
 
     _AQBANKING_SO_EFFECTIVE=$(awk '/AQBANKING_SO_EFFECTIVE / { print $3 }' ${AQBANKING_VERSION_H} )
     _GWENHYWFAR_SO_EFFECTIVE=$(awk '/GWENHYWFAR_SO_EFFECTIVE / { print $3 }' ${GWENHYWFAR_VERSION_H} )
@@ -300,7 +304,7 @@ function dist_finish() {
 
     if [ "$BUILD_FROM_TARBALL" = "no" ]; then
         # And changing output filename
-        PKG_VERSION=`grep PACKAGE_VERSION ${_BUILD_UDIR}/config.h | cut -d" " -f3 | cut -d\" -f2 `
+        PKG_VERSION=`grep PACKAGE_VERSION ${GNUCASH_CONFIG_H} | cut -d" " -f3 | cut -d\" -f2 `
         REVISION=`grep GNUCASH_SCM_REV ${_BUILD_UDIR}/src/core-utils/gnc-vcs-info.h | cut -d" " -f3 | cut -d\" -f2 `
         SETUP_FILENAME="gnucash-${PKG_VERSION}-$(date +'%Y-%m-%d')-${REPOS_TYPE}-${REVISION}-setup.exe"
         qpushd ${_GNUCASH_UDIR}

commit 58aa9094b23807d3c20b18691d5c7644a6d661b6
Author: Rob Gowin <robgowin at gmail.com>
Date:   Fri Apr 22 15:17:14 2016 -0500

    Fixes to build package under CMake
    
      * install-impl.sh: remove existing $_INSTALL_UDIR directory (e.g.
                      /c/gcdev/gnucash/inst)
    
      * dist-impl.sh: when using CMake, skip stuff that deals with *.la files,
                      which are autotools specific.

diff --git a/dist-impl.sh b/dist-impl.sh
index f37d324..116bc3d 100755
--- a/dist-impl.sh
+++ b/dist-impl.sh
@@ -245,7 +245,12 @@ function dist_gnucash() {
     cp -a $_INSTALL_UDIR/bin/* $_DIST_UDIR/bin
     mkdir -p $_DIST_UDIR/etc/gnucash
     cp -a $_INSTALL_UDIR/etc/gnucash/* $_DIST_UDIR/etc/gnucash
-    cp -a $_INSTALL_UDIR/lib/lib*.la $_DIST_UDIR/bin
+
+    # For CMake builds, there are no lib*.la files, so skip. 
+    if [ "$WITH_CMAKE" != "yes" ]; then
+        cp -a $_INSTALL_UDIR/lib/lib*.la $_DIST_UDIR/bin
+    fi 
+
     mkdir -p $_DIST_UDIR/share
     cp -a $_INSTALL_UDIR/share/{doc,gnucash,locale,glib-2.0} $_DIST_UDIR/share
     cp -a $_GC_WIN_REPOS_UDIR/extra_dist/{getperl.vbs,gnc-path-check,install-fq-mods.cmd} $_DIST_UDIR/bin
@@ -280,11 +285,15 @@ function dist_gnucash() {
 }
 
 function dist_finish() {
-    # Strip redirections in distributed libtool .la files
-    for file in $_DIST_UDIR/bin/*.la; do
-        cat $file | sed 's,^libdir=,#libdir=,' > $file.new
-        mv $file.new $file
-    done
+    if [ "$WITH_CMAKE" != "yes" ]; then
+        # Strip redirections in distributed libtool .la files.
+	# Skip this for CMake builds, which don't generate *.la files.
+
+        for file in $_DIST_UDIR/bin/*.la; do
+            cat $file | sed 's,^libdir=,#libdir=,' > $file.new
+            mv $file.new $file
+        done
+    fi;
 
     echo "Now running the Inno Setup Compiler for creating the setup.exe"
     ${_INNO_UDIR}/iscc //Q ${_GNUCASH_UDIR}/gnucash.iss
diff --git a/install-impl.sh b/install-impl.sh
index 81fa9a7..88f0e46 100644
--- a/install-impl.sh
+++ b/install-impl.sh
@@ -1330,6 +1330,13 @@ function inst_gnucash_using_cmake() {
     _LIBDBI_DRIVERS_UDIR=`unix_path ${LIBDBI_DRIVERS_DIR}`
     
     mkdir -p $_BUILD_UDIR
+
+    # Remove existing INSTALL_UDIR
+    if [ -x $_INSTALL_UDIR ]; then
+        echo Removing previous inst dir $_INSTALL_UDIR ...
+        rm -rf "$_INSTALL_UDIR"
+    fi;
+
     add_to_env $_INSTALL_UDIR/bin PATH
 
     if [ "$BUILD_FROM_TARBALL" != "yes" ]; then



Summary of changes:
 dist-impl.sh    | 27 ++++++++++++++++++++-------
 install-impl.sh |  7 +++++++
 2 files changed, 27 insertions(+), 7 deletions(-)



More information about the gnucash-changes mailing list