From 1823076f808c8be3d3bc9cd1f8376ce86e67bf0a7350214a3275f2a43dc04cc6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Ismail=20D=C3=B6nmez?= <ismail@i10z.com>
Date: Thu, 2 Jun 2016 16:50:15 +0000
Subject: [PATCH 1/2] Accepting request 399855 from home:rudi_m

- bump version 0.4.0, this is a feature release.
  * Bugfixes:
    - document %g/%G format specifiers
    - bug/42, accept NUL characters in input
    - bug/45, correctly display Gregorian and ISO week dates in one
      line
    - bug/46, adhere to ISO group's official formatting of week
      dates
    - bug/47, allow rounding of Epoch based timestamps
    - bug/48, avoid crash for void input to strptime(3)
  * Features:
    - datetest supports --isvalid to conditionalise on date/time
      parsing
    - all tools support --from-locale to parse localised input
    - tools with output formatting support --locale to format
      output according to locale
  * See info page examples and/or README.

OBS-URL: https://build.opensuse.org/request/show/399855
OBS-URL: https://build.opensuse.org/package/show/utilities/dateutils?expand=0&rev=48
---
 dateutils-0.3.5.tar.xz |  3 ---
 dateutils-0.4.0.tar.xz |  3 +++
 dateutils.changes      | 21 +++++++++++++++++++++
 dateutils.spec         |  5 +++--
 4 files changed, 27 insertions(+), 5 deletions(-)
 delete mode 100644 dateutils-0.3.5.tar.xz
 create mode 100644 dateutils-0.4.0.tar.xz

diff --git a/dateutils-0.3.5.tar.xz b/dateutils-0.3.5.tar.xz
deleted file mode 100644
index 48a5ddc..0000000
--- a/dateutils-0.3.5.tar.xz
+++ /dev/null
@@ -1,3 +0,0 @@
-version https://git-lfs.github.com/spec/v1
-oid sha256:cff341d3e6394627d98cb9643b9ca1235b839037ede58983c927df4f27ee31a7
-size 593112
diff --git a/dateutils-0.4.0.tar.xz b/dateutils-0.4.0.tar.xz
new file mode 100644
index 0000000..a5a9aff
--- /dev/null
+++ b/dateutils-0.4.0.tar.xz
@@ -0,0 +1,3 @@
+version https://git-lfs.github.com/spec/v1
+oid sha256:d05af02bc60a82bdc21c0ac4779f1040f631b0a1233ed15c4f69a80d3dad23da
+size 608364
diff --git a/dateutils.changes b/dateutils.changes
index 633699a..b16c9d7 100644
--- a/dateutils.changes
+++ b/dateutils.changes
@@ -1,3 +1,24 @@
+-------------------------------------------------------------------
+Thu Jun  2 14:07:21 UTC 2016 - sweet_f_a@gmx.de
+
+- bump version 0.4.0, this is a feature release.
+  * Bugfixes:
+    - document %g/%G format specifiers
+    - bug/42, accept NUL characters in input
+    - bug/45, correctly display Gregorian and ISO week dates in one
+      line
+    - bug/46, adhere to ISO group's official formatting of week
+      dates
+    - bug/47, allow rounding of Epoch based timestamps
+    - bug/48, avoid crash for void input to strptime(3)
+  * Features:
+    - datetest supports --isvalid to conditionalise on date/time
+      parsing
+    - all tools support --from-locale to parse localised input
+    - tools with output formatting support --locale to format
+      output according to locale
+  * See info page examples and/or README. 
+
 -------------------------------------------------------------------
 Fri Jan 22 22:45:28 UTC 2016 - sweet_f_a@gmx.de
 
diff --git a/dateutils.spec b/dateutils.spec
index a375685..00afd81 100644
--- a/dateutils.spec
+++ b/dateutils.spec
@@ -16,7 +16,7 @@
 #
 
 
-%define xversion 0.3.5
+%define xversion 0.4.0
 
 %define have_octave 0
 
@@ -39,7 +39,7 @@
 %endif
 
 Name:           dateutils
-Version:        0.3.5
+Version:        0.4.0
 Release:        0
 Summary:        Nifty command line date and time utilities
 License:        BSD-3-Clause
@@ -134,6 +134,7 @@ rm -rf %{buildroot}
 %{_bindir}/datezone
 %{_bindir}/strptime
 %dir %{_datadir}/dateutils/
+%{_datadir}/dateutils/locale
 %{_datadir}/dateutils/*.tzmcc
 %doc %{_infodir}/%{name}.info*
 %doc %{_mandir}/man1/%{name}.1*

From 18baff04df504a26ee7c6c4f3b265ac0d1e20927d56b3a443c9132cf724ab14e Mon Sep 17 00:00:00 2001
From: Ruediger Meier <sweet_f_a@gmx.de>
Date: Wed, 15 Jun 2016 10:12:15 +0000
Subject: [PATCH 2/2] - fix .mex file extension for octave plugin,  
 0001-Revert-chore-be-more-portable-in-sxe-matlab.m4.patch - explicit octave
 plugin file list - remove *.la files

OBS-URL: https://build.opensuse.org/package/show/utilities/dateutils?expand=0&rev=49
---
 ...re-be-more-portable-in-sxe-matlab.m4.patch | 86 +++++++++++++++++++
 dateutils.changes                             |  8 ++
 dateutils.spec                                |  7 +-
 3 files changed, 100 insertions(+), 1 deletion(-)
 create mode 100644 0001-Revert-chore-be-more-portable-in-sxe-matlab.m4.patch

diff --git a/0001-Revert-chore-be-more-portable-in-sxe-matlab.m4.patch b/0001-Revert-chore-be-more-portable-in-sxe-matlab.m4.patch
new file mode 100644
index 0000000..ef50f0c
--- /dev/null
+++ b/0001-Revert-chore-be-more-portable-in-sxe-matlab.m4.patch
@@ -0,0 +1,86 @@
+From 98a8df78e1668f05df86b250c4ad12efb7490b24 Mon Sep 17 00:00:00 2001
+From: Sebastian Freundt <freundt@ga-group.nl>
+Date: Wed, 15 Jun 2016 09:26:02 +0000
+Subject: [PATCH] Revert "chore, be more portable in sxe-matlab.m4"
+
+This reverts commit 471c813a4fb6d26f828cd7c191cfd1ec478a2bd8.
+
+This makes the matlab detection fail on systems with older shells.
+
+Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
+---
+ m4/sxe-matlab.m4 | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/m4/sxe-matlab.m4 b/m4/sxe-matlab.m4
+index 77fc708..5f1099e 100644
+--- a/m4/sxe-matlab.m4
++++ b/m4/sxe-matlab.m4
+@@ -3,10 +3,10 @@ AC_DEFUN([SXE_CHECK_MATLAB], [dnl
+ 	foo=`mktemp /tmp/sxe_check_matlab.XXXXXXXXXX`
+ 
+ 	AC_ARG_VAR([MATLAB], [full path to matlab binary])
+-	sxe_cv_matlab="${MATLAB-matlab}"
++	sxe_cv_matlab="${MATLAB:-matlab}"
+ 
+ 	AC_ARG_VAR([MATLABPATH], [path to matlab toolboxes])
+-	sxe_cv_matlabpath="${MATLABPATH-no}"
++	sxe_cv_matlabpath="${MATLABPATH:-no}"
+ 
+ 	AC_MSG_CHECKING([for matlab root])
+ 	## assume no matlab
+@@ -35,9 +35,9 @@ AC_DEFUN([SXE_CHECK_MATLAB], [dnl
+ 
+ 	AC_MSG_CHECKING([for matlab mex file extension])
+ 	sxe_cv_mexext=`"${MATLABROOT}/bin/mexext" 2>/dev/null`
+-	MEXEXT="${sxe_cv_mexext-mex}"
++	MEXEXT="${sxe_cv_mexext:-mex}"
+ 	AC_SUBST([MEXEXT])
+-	AC_MSG_RESULT([${sxe_cv_mexext-mex (assumed)}])
++	AC_MSG_RESULT([${sxe_cv_mexext:-mex (assumed)}])
+ 
+ 	## now reset *our* idea of what MATLAB should be
+ 	MATLAB="${sxe_cv_matlab}"
+@@ -70,7 +70,7 @@ AC_DEFUN([SXE_CHECK_OCTAVE], [dnl
+ 	AC_ARG_VAR([octave_LIBS], [library directives for octave linking])
+ 
+ 	AC_ARG_VAR([OCTAVEPATH], [path to octave toolboxes])
+-	sxe_cv_octavepath="${OCTAVEPATH-no}"
++	sxe_cv_octavepath="${OCTAVEPATH:-no}"
+ 
+ 	## prep the octave extension path, this is twofold
+ 	AC_PATH_PROG([OCTAVE_CONFIG], [octave-config])
+-- 
+1.8.5.6
+
+--- dateutils-0.4.0.orig/configure	2016-05-20 10:26:30.000000000 +0200
++++ dateutils-0.4.0/configure	2016-06-15 11:46:51.339401361 +0200
+@@ -10376,10 +10396,10 @@
+ 		foo=`mktemp /tmp/sxe_check_matlab.XXXXXXXXXX`
+ 
+ 
+-	sxe_cv_matlab="${MATLAB-matlab}"
++	sxe_cv_matlab="${MATLAB:-matlab}"
+ 
+ 
+-	sxe_cv_matlabpath="${MATLABPATH-no}"
++	sxe_cv_matlabpath="${MATLABPATH:-no}"
+ 
+ 	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for matlab root" >&5
+ $as_echo_n "checking for matlab root... " >&6; }
+@@ -10413,10 +10433,10 @@
+ 	{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for matlab mex file extension" >&5
+ $as_echo_n "checking for matlab mex file extension... " >&6; }
+ 	sxe_cv_mexext=`"${MATLABROOT}/bin/mexext" 2>/dev/null`
+-	MEXEXT="${sxe_cv_mexext-mex}"
++	MEXEXT="${sxe_cv_mexext:-mex}"
+ 
+-	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${sxe_cv_mexext-mex (assumed)}" >&5
+-$as_echo "${sxe_cv_mexext-mex (assumed)}" >&6; }
++	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${sxe_cv_mexext:-mex (assumed)}" >&5
++$as_echo "${sxe_cv_mexext:-mex (assumed)}" >&6; }
+ 
+ 	## now reset *our* idea of what MATLAB should be
+ 	MATLAB="${sxe_cv_matlab}"
+ 
+ 
diff --git a/dateutils.changes b/dateutils.changes
index b16c9d7..3b3cfb9 100644
--- a/dateutils.changes
+++ b/dateutils.changes
@@ -1,3 +1,11 @@
+-------------------------------------------------------------------
+Wed Jun 15 10:06:41 UTC 2016 - sweet_f_a@gmx.de
+
+- fix .mex file extension for octave plugin,
+  0001-Revert-chore-be-more-portable-in-sxe-matlab.m4.patch
+- explicit octave plugin file list
+- remove *.la files
+
 -------------------------------------------------------------------
 Thu Jun  2 14:07:21 UTC 2016 - sweet_f_a@gmx.de
 
diff --git a/dateutils.spec b/dateutils.spec
index 00afd81..e08658a 100644
--- a/dateutils.spec
+++ b/dateutils.spec
@@ -46,6 +46,8 @@ License:        BSD-3-Clause
 Group:          Productivity/Text/Utilities
 Url:            https://github.com/hroptatyr/dateutils/
 Source:         https://bitbucket.org/hroptatyr/dateutils/downloads/%{name}-%{version}.tar.xz
+# PATCH-FIX-UPSTREAM
+Patch1:         0001-Revert-chore-be-more-portable-in-sxe-matlab.m4.patch
 BuildRequires:  pkgconfig
 BuildRequires:  xz
 %if 0%{?suse_version}
@@ -78,6 +80,7 @@ Dateutils can be used from within matlab or ocatave.
 
 %prep
 %setup -q -n %{name}-%{xversion}
+%patch1 -p1
 
 %build
 %configure \
@@ -91,6 +94,7 @@ make V=1
 %install
 %{?make_install} %{!?make_install:make install DESTDIR=%{buildroot}}
 rm -f %{buildroot}%{_infodir}/dir
+rm -f %{buildroot}%{_libdir}/octave/site/oct/*/dateutils/tzconv.la
 
 %check
 if ! make check; then
@@ -162,7 +166,8 @@ rm -rf %{buildroot}
 %files octave
 %defattr(-,root,root)
 %dir %{_libdir}/octave/site/oct/*/dateutils/
-%{_libdir}/octave/site/oct/*/dateutils/*
+%{_libdir}/octave/site/oct/*/dateutils/tzconv.m
+%{_libdir}/octave/site/oct/*/dateutils/tzconv.mex
 %endif
 
 %changelog