gnucash unstable: Multiple changes pushed
John Ralls
jralls at code.gnucash.org
Fri Dec 1 18:26:07 EST 2017
Updated via https://github.com/Gnucash/gnucash/commit/2be5642a (commit)
via https://github.com/Gnucash/gnucash/commit/778b86e2 (commit)
from https://github.com/Gnucash/gnucash/commit/0a8e5006 (commit)
commit 2be5642a7d8e63741ae140a259e2b8369b42e9fc
Author: John Ralls <jralls at ceridwen.us>
Date: Fri Dec 1 15:25:28 2017 -0800
Fix autotools build after removing gnucash/overrides.
diff --git a/configure.ac b/configure.ac
index d1a680b..21d62ad 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1654,7 +1654,6 @@ AC_CONFIG_FILES(
doc/Makefile
doc/examples/Makefile
gnucash/Makefile
- gnucash/overrides/Makefile
gnucash/test/Makefile
gnucash/gnome/Makefile
gnucash/gnome/gtkbuilder/Makefile
@@ -1782,8 +1781,7 @@ AC_CONFIG_FILES([libgnucash/backend/xml/test/test-real-data.sh],
AC_CONFIG_FILES([gnucash/test/test-version],
[chmod +x gnucash/test/test-version])
-# A few files need extra actions at creation time
-AC_CONFIG_FILES([gnucash/overrides/gnucash-make-guids], [chmod u+x gnucash/overrides/gnucash-make-guids])
+
#Link (copy on Windows) test data files:
AC_CONFIG_LINKS([gnucash/import-export/csv-imp/test/sample1.csv:gnucash/import-export/csv-imp/test/sample1.csv])
LDFLAGS="${LDFLAGS} ${NOUNDEF}"
diff --git a/gnucash/Makefile.am b/gnucash/Makefile.am
index c79855f..8170ee7 100644
--- a/gnucash/Makefile.am
+++ b/gnucash/Makefile.am
@@ -1,9 +1,6 @@
if WITH_PYTHON
PYTHON_DIR = python
endif
-if !PLATFORM_WIN32
- OVERRIDES_DIR = overrides
-endif
# Order is important here.
SUBDIRS = \
${PYTHON_DIR} \
@@ -15,7 +12,6 @@ SUBDIRS = \
gnome \
import-export \
. \
- ${OVERRIDES_DIR} \
test
AM_CPPFLAGS = -I${top_builddir} ${GLIB_CFLAGS} ${GNOME_CFLAGS} ${GTK_CFLAGS} \
commit 778b86e29e3d82ef076fd9df80509490061c2bcf
Author: Rob Gowin <robgowin at gmail.com>
Date: Fri Dec 1 12:53:17 2017 -0600
Handle cases where LIBDIR is not "lib"
For example, Fedora installs to lib64, Debian to lib/<arch-tuple>
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0dc6124..bf9732f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -88,8 +88,10 @@ SET(TEST_MYSQL_URL "" CACHE STRING "MySQL database URL for testing")
SET(TEST_PGSQL_URL "" CACHE STRING "PgSQL database URL for testing")
SET(DATADIR_BUILD ${CMAKE_BINARY_DIR}/${DATADIRNAME})
-SET(LIBDIR_BUILD ${CMAKE_BINARY_DIR}/lib)
+STRING(REPLACE ${CMAKE_INSTALL_PREFIX} "" LIBDIR_BUILD ${LIBDIR})
+SET(LIBDIR_BUILD ${CMAKE_BINARY_DIR}/${LIBDIR_BUILD})
SET(SYSCONFDIR_BUILD ${CMAKE_BINARY_DIR}/etc)
+SET(LIBEXECDIR_BUILD ${CMAKE_BINARY_DIR}/libexec)
SET(BINDIR_BUILD ${CMAKE_BINARY_DIR}/bin)
SET(SHELL_FROM_ENV $ENV{SHELL})
@@ -506,13 +508,13 @@ SET(BUILD_SHARED_LIBS ON)
# (after the targets have been read in).
-SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/gnucash)
+SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${LIBDIR_BUILD}/gnucash)
IF (XCODE_VERSION)
# FIXME: These settings break the ability to manipulate different configurations (Debug,
# FIXME: Release, etc.) in Xcode. We'll need to change the module loading C code if
# we want to support multi config.
- SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY_DEBUG ${CMAKE_BINARY_DIR}/lib/gnucash)
- SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE ${CMAKE_BINARY_DIR}/lib/gnucash)
+ SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY_DEBUG ${LIBDIR_BUILD}/gnucash)
+ SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE ${LIBDIR_BUILD}/gnucash)
ENDIF()
# For binarines
@@ -808,10 +810,10 @@ add_custom_target(uninstall
SET_TARGET_PROPERTIES(gnc-core-utils gnc-module gnc-backend-sql gnc-backend-xml-utils
gnc-gnome PROPERTIES
- LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
+ LIBRARY_OUTPUT_DIRECTORY ${LIBDIR_BUILD}
IF (XCODE_VERSION)
- LIBRARY_OUTPUT_DIRECTORY_DEBUG ${CMAKE_BINARY_DIR}/lib
- LIBRARY_OUTPUT_DIRECTORY_RELEASE ${CMAKE_BINARY_DIR}/lib
+ LIBRARY_OUTPUT_DIRECTORY_DEBUG ${LIBDIR_BUILD}
+ LIBRARY_OUTPUT_DIRECTORY_RELEASE ${LIBDIR_BUILD}
ENDIF()
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin
diff --git a/common/cmake_modules/GncAddTest.cmake b/common/cmake_modules/GncAddTest.cmake
index fa8a8c5..0f11a63 100644
--- a/common/cmake_modules/GncAddTest.cmake
+++ b/common/cmake_modules/GncAddTest.cmake
@@ -1,7 +1,7 @@
FUNCTION(GET_GUILE_ENV)
- SET(_GNC_MODULE_PATH ${CMAKE_BINARY_DIR}/lib:${CMAKE_BINARY_DIR}/lib/gnucash)
+ SET(_GNC_MODULE_PATH ${LIBDIR_BUILD}:${LIBDIR_BUILD}/gnucash)
IF (WIN32)
SET(_GNC_MODULE_PATH ${CMAKE_BINARY_DIR}/bin)
ENDIF()
@@ -25,7 +25,7 @@ FUNCTION(GET_GUILE_ENV)
set(fpath "${fpath}${dir}:")
endforeach(dir)
LIST(APPEND env "PATH=${fpath}")
- set(compiled_path "${CMAKE_BINARY_DIR}/lib/gnucash/scm/ccache/2.0")
+ set(compiled_path "${LIBDIR_BUILD}/gnucash/scm/ccache/2.0")
string(REGEX REPLACE "^([A-Za-z]):" "/\\1" compiled_path ${compiled_path})
LIST(APPEND env GUILE_LOAD_COMPILED_PATH=${compiled_path})
ENDIF(MINGW64)
@@ -33,7 +33,7 @@ FUNCTION(GET_GUILE_ENV)
LIST(APPEND env "GUILE=${GUILE_EXECUTABLE}")
IF (NOT WIN32)
- LIST(APPEND env "GUILE_LOAD_COMPILED_PATH=${CMAKE_BINARY_DIR}/lib/gnucash/scm/ccache/2.0")
+ LIST(APPEND env "GUILE_LOAD_COMPILED_PATH=${LIBDIR_BUILD}/gnucash/scm/ccache/2.0")
ENDIF()
SET(guile_load_paths "")
LIST(APPEND guile_load_paths ${CMAKE_CURRENT_SOURCE_DIR}/mod-foo)
diff --git a/libgnucash/core-utils/binreloc.c b/libgnucash/core-utils/binreloc.c
index b44115f..55b7905 100644
--- a/libgnucash/core-utils/binreloc.c
+++ b/libgnucash/core-utils/binreloc.c
@@ -33,6 +33,7 @@
#ifndef __BINRELOC_C__
#define __BINRELOC_C__
#include <config.h>
+#include "gncla-dir.h"
#include <platform.h>
#if PLATFORM(WINDOWS)
@@ -548,7 +549,7 @@ gnc_gbr_find_lib_dir (const gchar *default_lib_dir)
return NULL;
}
- dir = g_build_filename (prefix, "lib", NULL);
+ dir = g_build_filename (prefix, LIBDIR, NULL);
g_free (prefix);
return dir;
}
diff --git a/libgnucash/engine/qof-backend.cpp b/libgnucash/engine/qof-backend.cpp
index 79943b1..06ee78c 100644
--- a/libgnucash/engine/qof-backend.cpp
+++ b/libgnucash/engine/qof-backend.cpp
@@ -28,6 +28,7 @@ extern "C"
#include <config.h>
#include "qof.h"
#include <gnc-path.h>
+#include "gncla-dir.h"
}
#include <string>
@@ -105,11 +106,11 @@ static char* get_default_module_dir(const char* rel_path)
{
#ifdef CMAKE_BUILD
#ifdef WIN32
- #define LIBDIR "bin"
+ #define MODULE_LIBDIR "bin"
#else
- #define LIBDIR "lib/gnucash"
+ #define MODULE_LIBDIR LIBDIR "/gnucash"
#endif
- pkglibdir = g_build_path (G_DIR_SEPARATOR_S, builddir, LIBDIR, NULL);
+ pkglibdir = g_build_path (G_DIR_SEPARATOR_S, builddir, MODULE_LIBDIR, NULL);
#else
if (rel_path)
pkglibdir = g_build_path (G_DIR_SEPARATOR_S, builddir,
diff --git a/libgnucash/gnc-module/test/CMakeLists.txt b/libgnucash/gnc-module/test/CMakeLists.txt
index a6ab0ee..f666299 100644
--- a/libgnucash/gnc-module/test/CMakeLists.txt
+++ b/libgnucash/gnc-module/test/CMakeLists.txt
@@ -22,7 +22,7 @@ FUNCTION(RUN_TEST_WITH_GUILE _TARGET _SOURCE_FILE)
GET_GUILE_ENV()
SET(CMAKE_COMMAND_TMP "")
IF (${CMAKE_VERSION} VERSION_GREATER 3.1)
- SET(CMAKE_COMMAND_TMP ${CMAKE_COMMAND} -E env "${GUILE_ENV};GNC_MODULE_PATH=${CMAKE_BINARY_DIR}/lib/gnucash/test")
+ SET(CMAKE_COMMAND_TMP ${CMAKE_COMMAND} -E env "${GUILE_ENV};GNC_MODULE_PATH=$${LIBDIR_BUILD}/gnucash/test")
ENDIF()
ADD_TEST(NAME ${_TARGET}
COMMAND ${CMAKE_COMMAND_TMP}
@@ -32,7 +32,7 @@ FUNCTION(RUN_TEST_WITH_GUILE _TARGET _SOURCE_FILE)
SET_TESTS_PROPERTIES(${_TARGET} PROPERTIES ENVIRONMENT "${GUILE_ENV};${ARGN}")
ENDFUNCTION()
-GNC_ADD_TEST_WITH_GUILE(test-load-c test-load-c.c GNC_MODULE_TEST_INCLUDE_DIRS GNC_MODULE_TEST_LIBS "GNC_MODULE_PATH=${CMAKE_BINARY_DIR}/lib/gnucash/test")
+GNC_ADD_TEST_WITH_GUILE(test-load-c test-load-c.c GNC_MODULE_TEST_INCLUDE_DIRS GNC_MODULE_TEST_LIBS "GNC_MODULE_PATH=${LIBDIR_BUILD}/gnucash/test")
GNC_ADD_TEST_WITH_GUILE(test-modsysver test-modsysver.c
GNC_MODULE_TEST_INCLUDE_DIRS GNC_MODULE_TEST_LIBS
@@ -42,10 +42,10 @@ GNC_ADD_TEST_WITH_GUILE(test-incompatdep test-incompatdep.c
)
GNC_ADD_TEST_WITH_GUILE(test-agedver test-agedver.c
GNC_MODULE_TEST_INCLUDE_DIRS GNC_MODULE_TEST_LIBS
- "GNC_MODULE_PATH=${CMAKE_BINARY_DIR}/lib/gnucash/test"
+ "GNC_MODULE_PATH=${LIBDIR_BUILD}/gnucash/test"
)
-SET(_LIBDIR ${CMAKE_BINARY_DIR}/lib)
+SET(_LIBDIR ${LIBDIR_BUILD})
IF (WIN32)
SET(_LIBDIR ${CMAKE_BINARY_DIR}/bin)
ENDIF()
@@ -78,7 +78,7 @@ IF(NOT WIN32)
# This little dance is needed because gnc_module_init will assert if
# it finds libgncmod_futuremod.so outside of a test that expects it.
GET_GUILE_ENV()
- SET(_GNC_MODULE_PATH "${CMAKE_BINARY_DIR}/lib:${CMAKE_BINARY_DIR}/lib/gnucash:${CMAKE_BINARY_DIR}/lib/gnucash/test")
+ SET(_GNC_MODULE_PATH "${LIBDIR_BUILD}:${LIBDIR_BUILD}/gnucash:${LIBDIR_BUILD}/gnucash/test")
FOREACH(test_file ${test_gnc_module_SCHEME})
GET_FILENAME_COMPONENT(basename ${test_file} NAME_WE)
SET_TESTS_PROPERTIES(${basename} PROPERTIES ENVIRONMENT "${GUILE_ENV};GNC_MODULE_PATH=${_GNC_MODULE_PATH}")
diff --git a/libgnucash/gnc-module/test/misc-mods/CMakeLists.txt b/libgnucash/gnc-module/test/misc-mods/CMakeLists.txt
index 49a0520..e9a5b99 100644
--- a/libgnucash/gnc-module/test/misc-mods/CMakeLists.txt
+++ b/libgnucash/gnc-module/test/misc-mods/CMakeLists.txt
@@ -14,8 +14,8 @@ ADD_LIBRARY(gncmod_incompatdep EXCLUDE_FROM_ALL incompatdep.c)
TARGET_LINK_LIBRARIES(gncmod_incompatdep gnc-module ${GLIB2_LDFLAGS})
SET_TARGET_PROPERTIES(gncmod_agedver gncmod_futuremodsys gncmod_incompatdep PROPERTIES
-LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/gnucash/test
-ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/gnucash/test
+LIBRARY_OUTPUT_DIRECTORY ${LIBDIR_BUILD}/gnucash/test
+ARCHIVE_OUTPUT_DIRECTORY ${LIBDIR_BUILD}/gnucash/test
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
SET_DIST_LIST(misc_mods_DIST CMakeLists.txt Makefile.am agedver.c futuremodsys.c incompatdep.c)
diff --git a/libgnucash/gnc-module/test/mod-bar/CMakeLists.txt b/libgnucash/gnc-module/test/mod-bar/CMakeLists.txt
index 8a90648..56f9f21 100644
--- a/libgnucash/gnc-module/test/mod-bar/CMakeLists.txt
+++ b/libgnucash/gnc-module/test/mod-bar/CMakeLists.txt
@@ -22,8 +22,8 @@ TARGET_INCLUDE_DIRECTORIES(gncmodbar PRIVATE
)
SET_TARGET_PROPERTIES(bar gncmodbar PROPERTIES
-LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/gnucash/test
-ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/gnucash/test
+LIBRARY_OUTPUT_DIRECTORY ${LIBDIR_BUILD}/gnucash/test
+ARCHIVE_OUTPUT_DIRECTORY ${LIBDIR_BUILD}/gnucash/test
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
SET_DIST_LIST(mod_bar_DIST CMakeLists.txt Makefile.am bar.c gnucash/bar.scm bar.h bar.i gnc-mod-bar.c)
diff --git a/libgnucash/gnc-module/test/mod-baz/CMakeLists.txt b/libgnucash/gnc-module/test/mod-baz/CMakeLists.txt
index 17c3c56..6f18ed8 100644
--- a/libgnucash/gnc-module/test/mod-baz/CMakeLists.txt
+++ b/libgnucash/gnc-module/test/mod-baz/CMakeLists.txt
@@ -35,8 +35,8 @@ GNC_ADD_SCHEME_TARGETS(scm-mod-baz
)
SET_TARGET_PROPERTIES(baz gncmodbaz PROPERTIES
-LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/gnucash/test
-ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/gnucash/test
+LIBRARY_OUTPUT_DIRECTORY ${LIBDIR_BUILD}/gnucash/test
+ARCHIVE_OUTPUT_DIRECTORY ${LIBDIR_BUILD}/gnucash/test
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
SET_DIST_LIST(mod_baz_DIST CMakeLists.txt Makefile.am baz.c gnucash/baz.scm baz.h baz.i gnc-mod-baz.c)
diff --git a/libgnucash/gnc-module/test/mod-foo/CMakeLists.txt b/libgnucash/gnc-module/test/mod-foo/CMakeLists.txt
index 0a6d37f..ba8cb42 100644
--- a/libgnucash/gnc-module/test/mod-foo/CMakeLists.txt
+++ b/libgnucash/gnc-module/test/mod-foo/CMakeLists.txt
@@ -29,8 +29,8 @@ GNC_ADD_SCHEME_TARGETS(scm-mod-foo
)
SET_TARGET_PROPERTIES(foo gncmodfoo PROPERTIES
-LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/gnucash/test
-ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/gnucash/test
+LIBRARY_OUTPUT_DIRECTORY ${LIBDIR_BUILD}/gnucash/test
+ARCHIVE_OUTPUT_DIRECTORY ${LIBDIR_BUILD}/gnucash/test
RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
SET_DIST_LIST(mod_foo_DIST CMakeLists.txt Makefile.am foo.i gnucash/foo.scm foo.c foo.h gnc-mod-foo.c)
Summary of changes:
CMakeLists.txt | 16 +++++++++-------
common/cmake_modules/GncAddTest.cmake | 6 +++---
configure.ac | 4 +---
gnucash/Makefile.am | 4 ----
libgnucash/core-utils/binreloc.c | 3 ++-
libgnucash/engine/qof-backend.cpp | 7 ++++---
libgnucash/gnc-module/test/CMakeLists.txt | 10 +++++-----
libgnucash/gnc-module/test/misc-mods/CMakeLists.txt | 4 ++--
libgnucash/gnc-module/test/mod-bar/CMakeLists.txt | 4 ++--
libgnucash/gnc-module/test/mod-baz/CMakeLists.txt | 4 ++--
libgnucash/gnc-module/test/mod-foo/CMakeLists.txt | 4 ++--
11 files changed, 32 insertions(+), 34 deletions(-)
More information about the gnucash-changes
mailing list