Navigation Menu

Skip to content

Commit

Permalink
Merge branch 'maint'
Browse files Browse the repository at this point in the history
  • Loading branch information
gjanssens committed Oct 3, 2016
2 parents 921b5a9 + cd8182f commit 87ed53b
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 54 deletions.
1 change: 1 addition & 0 deletions accounts/de_DE/acctchrt_wohnungsw.gnucash-xea
Expand Up @@ -64,6 +64,7 @@
<slot:value type="string">true</slot:value>
</slot>
</act:slots>
<act:parent type="new">1972cce2e2364f95b2b0bc014502661d</act:parent>
</gnc:account>
<gnc:account version="2.0.0">
<act:name>00 Grundstücke mit Wohnbauten</act:name>
Expand Down
7 changes: 0 additions & 7 deletions configure.ac
Expand Up @@ -645,7 +645,6 @@ fi

LIBXML2_REQUIRED=2.5.10
PKG_CHECK_MODULES(LIBXML2, libxml-2.0 >= $LIBXML2_REQUIRED)
AS_SCRUB_INCLUDE(LIBXML2_CFLAGS)
AC_SUBST(LIBXML2_CFLAGS)
AC_SUBST(LIBXML2_LIBS)

Expand All @@ -662,7 +661,6 @@ LIBS="$oLIBS"
### LIBXSLT

PKG_CHECK_MODULES(LIBXSLT, libxslt)
AS_SCRUB_INCLUDE(LIBXLT_CFLAGS)
AC_SUBST(LIBXSLT_CFLAGS)
AC_SUBST(LIBXSLT_LIBS)

Expand Down Expand Up @@ -1142,7 +1140,6 @@ then
AQBANKING_LIBS="${AQBANKING_LIBS} -lktoblzcheck"
fi

AS_SCRUB_INCLUDE(AQBANKING_CFLAGS)
AC_SUBST(AQBANKING_LIBS)
AC_SUBST(AQBANKING_CFLAGS)
_COMPONENTS="$_COMPONENTS aqbanking"
Expand Down Expand Up @@ -1362,23 +1359,19 @@ then
CFLAGS="$__cflags"

PKG_CHECK_MODULES(GTK, gtk+-2.0 >= 2.24.0)
AS_SCRUB_INCLUDE(GTK_CFLAGS)
AC_SUBST(GTK_CFLAGS)
AC_SUBST(GTK_LIBS)

PKG_CHECK_MODULES(GNOMECANVAS, libgnomecanvas-2.0)
AS_SCRUB_INCLUDE(GNOMECANVAS_CFLAGS)
AC_SUBST(GNOMECANVAS_CFLAGS)
AC_SUBST(GNOMECANVAS_LIBS)

PKG_CHECK_MODULES(GDK_PIXBUF, gdk-pixbuf-2.0)
AS_SCRUB_INCLUDE(GDK_PIXBUF_CFLAGS)
AC_SUBST(GDK_PIXBUF_CFLAGS)
AC_SUBST(GDK_PIXBUF_LIBS)

# checks for goffice
PKG_CHECK_MODULES(GOFFICE, libgoffice-0.8 >= 0.7.0 libgoffice-0.8 < 0.9.0, [goffice=1], [AC_MSG_ERROR([Cannot find libgoffice >= 0.7.0 and < 0.9.0])])
AS_SCRUB_INCLUDE(GOFFICE_CFLAGS)
AC_SUBST(GOFFICE_CFLAGS)
AC_SUBST(GOFFICE_LIBS)

Expand Down
32 changes: 0 additions & 32 deletions macros/as-scrub-include.m4

This file was deleted.

10 changes: 4 additions & 6 deletions src/cmake_modules/GncFindPkgConfig.cmake
@@ -1,4 +1,4 @@
if(${CMAKE_VERSION} VERSION_GREATER 3.1)
if((${CMAKE_VERSION} VERSION_GREATER 3.1) AND (${CMAKE_VERSION} VERSION_LESS 3.5))

function (pkg_get_variable result pkg variable)
_pkgconfig_invoke("${pkg}" "prefix" "result" "" "--variable=${variable}")
Expand Down Expand Up @@ -247,12 +247,10 @@ endmacro()

else()

include(FindPkgConfig)

macro(gnc_pkg_check_modules _prefix _module0)
if (NOT DEFINED __pkg_config_checked_${_prefix} OR __pkg_config_checked_${_prefix} LESS ${PKG_CONFIG_VERSION} OR NOT ${_prefix}_FOUND)
_pkgconfig_parse_options (_pkg_modules _pkg_is_required _pkg_is_silent "${_module0}" ${ARGN})
_pkg_check_modules_internal("${_pkg_is_required}" "${_pkg_is_silent}" "${_prefix}" ${_pkg_modules})
_pkgconfig_set(__pkg_config_checked_${_prefix} ${PKG_CONFIG_VERSION})
endif()
PKG_CHECK_MODULES(${_prefix} ${_module0} ${ARGN})
endmacro()

endif()
2 changes: 2 additions & 0 deletions src/plugins/bi_import/dialog-bi-import.c
Expand Up @@ -714,9 +714,11 @@ gnc_bi_import_create_bis (GtkListStore * store, QofBook * book,
{
qof_scan_date (date_opened, &day, &month, &year); // FIXME: Must check for the return value of qof_scan_date!
gncEntrySetDate(entry, gnc_dmy2timespec (day, month, year));
gncEntrySetDateEntered(entry, gnc_dmy2timespec (day, month, year));
}
else
{
gncEntrySetDate(entry, today);
gncEntrySetDateEntered(entry, today);
}
// Remove escaped quotes
Expand Down
2 changes: 1 addition & 1 deletion src/report/report-system/html-document.scm
Expand Up @@ -159,7 +159,7 @@
;;./share/gnucash/scm/gnucash/report/balsheet-eg.eguile.scm:<html>

;; Validate against HTML4 Transitional:
(push "<!DOCTYPE!DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN\" \n\"http://www.w3.org/TR/html4/loose.dtd\">")
(push "<!DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN\" \n\"http://www.w3.org/TR/html4/loose.dtd\">")
(push "<head>\n")
(push "<meta http-equiv=\"content-type\" content=\"text/html; charset=utf-8\" />\n")
(if css?
Expand Down
28 changes: 20 additions & 8 deletions src/report/report-system/test/test-report-utilities.scm
Expand Up @@ -18,19 +18,31 @@

(define (test-account-get-trans-type-splits-interval)
(let ((env (create-test-env))
(end-date (gnc:date->timepair (localtime (current-time)))))
(end-date-tp (gnc:date->timepair (localtime (current-time)))))
(let* ((accounts (env-create-account-structure-alist env (list "Assets"
(list (cons 'type ACCT-TYPE-ASSET))
(list "Bank Account")
(list "Wallet"))))
(bank-account (cdr (assoc "Bank Account" accounts)))
(wallet (cdr (assoc "Wallet" accounts))))

(env-create-daily-transactions env (decdate end-date (NDayDelta 10)) end-date bank-account wallet)
(wallet (cdr (assoc "Wallet" accounts)))
(start-date-tp (decdate end-date-tp (NDayDelta 10)))
(q-start-date-tp (decdate end-date-tp (NDayDelta 5)))
(q-start-date (gnc:timepair->date q-start-date-tp))
(q-end-date (gnc:timepair->date end-date-tp)))

(env-create-daily-transactions env start-date-tp end-date-tp bank-account wallet)

; Ensure the query interval is as inclusive as possible to deal with timezone differences
(set-tm:hour q-end-date 23)
(set-tm:min q-end-date 59)
(set-tm:sec q-end-date 59)
(set-tm:hour q-start-date 00)
(set-tm:min q-start-date 00)
(set-tm:sec q-start-date 01)

(let ((splits (gnc:account-get-trans-type-splits-interval (list bank-account wallet)
ACCT-TYPE-ASSET
(decdate end-date (NDayDelta 5))
end-date)))
;; 8 is the right number (4 days, two splits per tx)
(and (equal? 8 (length splits)))))))
(gnc:date->timepair q-start-date)
(gnc:date->timepair q-end-date))))
;; 10 is the right number (5 days, two splits per tx)
(and (equal? 10 (length splits)))))))

0 comments on commit 87ed53b

Please sign in to comment.