snapper: update to 0.8.7
Signed-off-by: Nathan Owens <ndowens04@gmail.com>
This commit is contained in:
parent
1d88a846b1
commit
7d772c879b
@ -1418,7 +1418,7 @@ libgfchangelog.so.0 libglusterfs-3.8.0_1
|
|||||||
libgfrpc.so.0 libglusterfs-3.8.0_1
|
libgfrpc.so.0 libglusterfs-3.8.0_1
|
||||||
libgfxdr.so.0 libglusterfs-3.8.0_1
|
libgfxdr.so.0 libglusterfs-3.8.0_1
|
||||||
libgfapi.so.0 libglusterfs-3.8.0_1
|
libgfapi.so.0 libglusterfs-3.8.0_1
|
||||||
libsnapper.so.4 libsnapper-0.4.1_1
|
libsnapper.so.5 libsnapper-0.4.1_1
|
||||||
libtsm.so.3 libtsm-3_1
|
libtsm.so.3 libtsm-3_1
|
||||||
libxine.so.2 libxine-1.2.4_1
|
libxine.so.2 libxine-1.2.4_1
|
||||||
libjbig2dec.so.0 libjbig2dec-0.11_1
|
libjbig2dec.so.0 libjbig2dec-0.11_1
|
||||||
|
26
srcpkgs/snapper/patches/0001-musl-sterror_r.patch
Normal file
26
srcpkgs/snapper/patches/0001-musl-sterror_r.patch
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
From a4068f03b471777151c4eb43fc70c3b6ebf8df3a Mon Sep 17 00:00:00 2001
|
||||||
|
From: Nathan Owens <ndowens04@gmail.com>
|
||||||
|
Date: Wed, 18 Dec 2019 18:23:38 -0600
|
||||||
|
Subject: [PATCH 1/4] musl-sterror_r
|
||||||
|
|
||||||
|
Signed-off-by: Nathan Owens <ndowens04@gmail.com>
|
||||||
|
---
|
||||||
|
snapper/AppUtil.cc | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/snapper/AppUtil.cc b/snapper/AppUtil.cc
|
||||||
|
index 553065c..2897276 100644
|
||||||
|
--- snapper/AppUtil.cc
|
||||||
|
+++ snapper/AppUtil.cc
|
||||||
|
@@ -223,7 +223,7 @@ namespace snapper
|
||||||
|
string
|
||||||
|
stringerror(int errnum)
|
||||||
|
{
|
||||||
|
-#if (_POSIX_C_SOURCE >= 200112L) && ! _GNU_SOURCE
|
||||||
|
+#if (_POSIX_C_SOURCE >= 200112L) && ! _GNU_SOURCE || MUSL_LIBC
|
||||||
|
char buf1[100];
|
||||||
|
if (strerror_r(errnum, buf1, sizeof(buf1) - 1) == 0)
|
||||||
|
return string(buf1);
|
||||||
|
--
|
||||||
|
2.24.1
|
||||||
|
|
26
srcpkgs/snapper/patches/0002-musl-mktime.patch
Normal file
26
srcpkgs/snapper/patches/0002-musl-mktime.patch
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
From 6385e34fb13dbfabd0b4b93f7670eac0c490637f Mon Sep 17 00:00:00 2001
|
||||||
|
From: Nathan Owens <ndowens04@gmail.com>
|
||||||
|
Date: Wed, 18 Dec 2019 18:24:08 -0600
|
||||||
|
Subject: [PATCH 2/4] musl-mktime
|
||||||
|
|
||||||
|
Signed-off-by: Nathan Owens <ndowens04@gmail.com>
|
||||||
|
---
|
||||||
|
snapper/AppUtil.cc | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/snapper/AppUtil.cc b/snapper/AppUtil.cc
|
||||||
|
index 2897276..64812d7 100644
|
||||||
|
--- snapper/AppUtil.cc
|
||||||
|
+++ snapper/AppUtil.cc
|
||||||
|
@@ -288,7 +288,7 @@ namespace snapper
|
||||||
|
const char* p = strptime(str.c_str(), "%F %T", &s);
|
||||||
|
if (!p || *p != '\0')
|
||||||
|
return (time_t)(-1);
|
||||||
|
- return utc ? timegm(&s) : timelocal(&s);
|
||||||
|
+ return utc ? timegm(&s) : mktime(&s);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
--
|
||||||
|
2.24.1
|
||||||
|
|
60
srcpkgs/snapper/patches/0003-musl-_nl_msg_cat_cntr.patch
Normal file
60
srcpkgs/snapper/patches/0003-musl-_nl_msg_cat_cntr.patch
Normal file
@ -0,0 +1,60 @@
|
|||||||
|
From 554bf69b4cfb5e91a20f0df0ac0fef918648fb48 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Nathan Owens <ndowens04@gmail.com>
|
||||||
|
Date: Wed, 18 Dec 2019 18:26:02 -0600
|
||||||
|
Subject: [PATCH 3/4] musl-_nl_msg_cat_cntr
|
||||||
|
|
||||||
|
Signed-off-by: Nathan Owens <ndowens04@gmail.com>
|
||||||
|
---
|
||||||
|
snapper/Regex.cc | 17 ++++++++++++-----
|
||||||
|
1 file changed, 12 insertions(+), 5 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/snapper/Regex.cc b/snapper/Regex.cc
|
||||||
|
index da8f862..6b2cd2d 100644
|
||||||
|
--- snapper/Regex.cc
|
||||||
|
+++ snapper/Regex.cc
|
||||||
|
@@ -21,9 +21,9 @@
|
||||||
|
|
||||||
|
#include <stdexcept>
|
||||||
|
#include "snapper/Regex.h"
|
||||||
|
-
|
||||||
|
+#ifdef __GLIBC__
|
||||||
|
extern int _nl_msg_cat_cntr;
|
||||||
|
-
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
namespace snapper
|
||||||
|
{
|
||||||
|
@@ -40,8 +40,10 @@ Regex::Regex (const string& pattern, int cflags, unsigned int nm)
|
||||||
|
regerror(errcode, &rx, error, esize);
|
||||||
|
throw std::runtime_error(string("Regex compilation error: ") + error);
|
||||||
|
}
|
||||||
|
+#ifdef __GLIBC__
|
||||||
|
my_nl_msg_cat_cntr = _nl_msg_cat_cntr;
|
||||||
|
- rm = new regmatch_t[nm];
|
||||||
|
+#endif
|
||||||
|
+ rm = new regmatch_t[nm];
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@@ -55,11 +57,16 @@ Regex::~Regex ()
|
||||||
|
bool
|
||||||
|
Regex::match (const string& str, int eflags) const
|
||||||
|
{
|
||||||
|
- if (my_nl_msg_cat_cntr != _nl_msg_cat_cntr) {
|
||||||
|
+#ifdef __GLIBC__
|
||||||
|
+ if (my_nl_msg_cat_cntr != _nl_msg_cat_cntr)
|
||||||
|
+#endif
|
||||||
|
+ {
|
||||||
|
regfree (&rx);
|
||||||
|
regcomp (&rx, pattern.c_str (), cflags);
|
||||||
|
+#ifdef __GLIBC__
|
||||||
|
my_nl_msg_cat_cntr = _nl_msg_cat_cntr;
|
||||||
|
- }
|
||||||
|
+#endif
|
||||||
|
+ }
|
||||||
|
|
||||||
|
last_str = str;
|
||||||
|
|
||||||
|
--
|
||||||
|
2.24.1
|
||||||
|
|
26
srcpkgs/snapper/patches/0004-musl-stdout_stderr.patch
Normal file
26
srcpkgs/snapper/patches/0004-musl-stdout_stderr.patch
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
From d519c3c94a029d6891b0703ce5adb6ea0ac8b9fa Mon Sep 17 00:00:00 2001
|
||||||
|
From: Nathan Owens <ndowens04@gmail.com>
|
||||||
|
Date: Wed, 18 Dec 2019 18:27:17 -0600
|
||||||
|
Subject: [PATCH 4/4] musl-stdout_stderr
|
||||||
|
|
||||||
|
Signed-off-by: Nathan Owens <ndowens04@gmail.com>
|
||||||
|
---
|
||||||
|
snapper/SystemCmd.h | 2 ++
|
||||||
|
1 file changed, 2 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/snapper/SystemCmd.h b/snapper/SystemCmd.h
|
||||||
|
index 3d38604..72bbb2b 100644
|
||||||
|
--- snapper/SystemCmd.h
|
||||||
|
+++ snapper/SystemCmd.h
|
||||||
|
@@ -32,6 +32,8 @@
|
||||||
|
#include <list>
|
||||||
|
#include <boost/noncopyable.hpp>
|
||||||
|
|
||||||
|
+#undef stdout
|
||||||
|
+#undef stderr
|
||||||
|
|
||||||
|
namespace snapper
|
||||||
|
{
|
||||||
|
--
|
||||||
|
2.24.1
|
||||||
|
|
@ -1,13 +0,0 @@
|
|||||||
The correct location is <poll.h>, not <sys/poll.h>
|
|
||||||
|
|
||||||
--- snapper/SystemCmd.h 2014-02-05 14:22:06.000000000 +0100
|
|
||||||
+++ snapper/SystemCmd.h 2015-08-30 10:56:03.685179465 +0200
|
|
||||||
@@ -23,7 +23,7 @@
|
|
||||||
#ifndef SNAPPER_SYSTEM_CMD_H
|
|
||||||
#define SNAPPER_SYSTEM_CMD_H
|
|
||||||
|
|
||||||
-#include <sys/poll.h>
|
|
||||||
+#include <poll.h>
|
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
#include <string>
|
|
@ -1,19 +0,0 @@
|
|||||||
The macro __isleap() is defined in glibc's time.h
|
|
||||||
If it is not defined, define it the same (for musl libc).
|
|
||||||
|
|
||||||
--- client/utils/equal-date.h 2014-12-11 18:21:17.000000000 +0100
|
|
||||||
+++ client/utils/equal-date.h 2015-08-30 11:18:08.181207315 +0200
|
|
||||||
@@ -19,6 +19,13 @@
|
|
||||||
* find current contact information at www.novell.com.
|
|
||||||
*/
|
|
||||||
|
|
||||||
+#if !defined(__isleap)
|
|
||||||
+/* Nonzero if YEAR is a leap year (every 4 years,
|
|
||||||
+ except every 100th isn't, and every 400th is). */
|
|
||||||
+# define __isleap(year) \
|
|
||||||
+ ((year) % 4 == 0 && ((year) % 100 != 0 || (year) % 400 == 0))
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
|
|
||||||
bool
|
|
||||||
equal_year(const struct tm& tmp1, const struct tm& tmp2);
|
|
@ -1,51 +0,0 @@
|
|||||||
There is no _nl_msg_cat_cntr in musl libc and optimizations
|
|
||||||
based upon its unchanged value are not possible.
|
|
||||||
|
|
||||||
--- snapper/Regex.cc 2014-01-29 16:48:30.000000000 +0100
|
|
||||||
+++ snapper/Regex.cc 2015-08-30 11:07:34.613193993 +0200
|
|
||||||
@@ -22,7 +22,9 @@
|
|
||||||
|
|
||||||
#include "snapper/Regex.h"
|
|
||||||
|
|
||||||
+#if defined(__GLIBC__)
|
|
||||||
extern int _nl_msg_cat_cntr;
|
|
||||||
+#endif
|
|
||||||
|
|
||||||
|
|
||||||
namespace snapper
|
|
||||||
@@ -34,7 +36,9 @@
|
|
||||||
nm (cflags & REG_NOSUB ? 0 : nm)
|
|
||||||
{
|
|
||||||
regcomp (&rx, pattern, cflags);
|
|
||||||
+#if defined(__GLIBC__)
|
|
||||||
my_nl_msg_cat_cntr = _nl_msg_cat_cntr;
|
|
||||||
+#endif
|
|
||||||
rm = new regmatch_t[nm];
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -45,7 +49,9 @@
|
|
||||||
nm (cflags & REG_NOSUB ? 0 : nm)
|
|
||||||
{
|
|
||||||
regcomp (&rx, pattern.c_str (), cflags);
|
|
||||||
+#if defined(__GLIBC__)
|
|
||||||
my_nl_msg_cat_cntr = _nl_msg_cat_cntr;
|
|
||||||
+#endif
|
|
||||||
rm = new regmatch_t[nm];
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -60,11 +66,15 @@
|
|
||||||
bool
|
|
||||||
Regex::match (const string& str, int eflags) const
|
|
||||||
{
|
|
||||||
+#if defined(__GLIBC__)
|
|
||||||
if (my_nl_msg_cat_cntr != _nl_msg_cat_cntr) {
|
|
||||||
+#endif
|
|
||||||
regfree (&rx);
|
|
||||||
regcomp (&rx, pattern.c_str (), cflags);
|
|
||||||
+#if defined(__GLIBC__)
|
|
||||||
my_nl_msg_cat_cntr = _nl_msg_cat_cntr;
|
|
||||||
}
|
|
||||||
+#endif
|
|
||||||
|
|
||||||
last_str = str;
|
|
||||||
|
|
@ -1,15 +0,0 @@
|
|||||||
According to http://ftp.gnu.org/old-gnu/Manuals/glibc-2.2.3/html_chapter/libc_21.html
|
|
||||||
timelocal(2) is functionally identical to mktime(2), but more
|
|
||||||
mnemonically named. There is no timelocal(2) defined in musl libc.
|
|
||||||
|
|
||||||
--- snapper/AppUtil.cc 2015-02-18 18:54:03.000000000 +0100
|
|
||||||
+++ snapper/AppUtil.cc 2015-08-30 10:39:31.318158599 +0200
|
|
||||||
@@ -274,7 +274,7 @@
|
|
||||||
const char* p = strptime(str.c_str(), "%F %T", &s);
|
|
||||||
if (!p || *p != '\0')
|
|
||||||
return (time_t)(-1);
|
|
||||||
- return utc ? timegm(&s) : timelocal(&s);
|
|
||||||
+ return utc ? timegm(&s) : mktime(&s);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
@ -1,12 +0,0 @@
|
|||||||
The mode_t type is defined in fcntl.h
|
|
||||||
|
|
||||||
--- snapper/FileUtils.h 2015-02-18 18:54:03.000000000 +0100
|
|
||||||
+++ snapper/FileUtils.h 2015-08-30 10:45:43.285166420 +0200
|
|
||||||
@@ -24,6 +24,7 @@
|
|
||||||
#define SNAPPER_FILE_UTILS_H
|
|
||||||
|
|
||||||
|
|
||||||
+#include <fcntl.h>
|
|
||||||
#include <string>
|
|
||||||
#include <vector>
|
|
||||||
#include <functional>
|
|
@ -1,15 +0,0 @@
|
|||||||
In musl libc stdout and stderr are macros, thus we need to
|
|
||||||
undefine them to be able to use SystemCmd::stdout() and ::stderr()
|
|
||||||
members without renaming them - which may be a better choice.
|
|
||||||
|
|
||||||
--- snapper/SystemCmd.h 2015-08-30 10:59:53.740184303 +0200
|
|
||||||
+++ snapper/SystemCmd.h 2015-08-30 11:02:34.229187677 +0200
|
|
||||||
@@ -31,6 +31,8 @@
|
|
||||||
#include <list>
|
|
||||||
#include <boost/noncopyable.hpp>
|
|
||||||
|
|
||||||
+#undef stdout
|
|
||||||
+#undef stderr
|
|
||||||
|
|
||||||
namespace snapper
|
|
||||||
{
|
|
@ -1,14 +0,0 @@
|
|||||||
In musl libc the return type of strerror_r(2) is int (XSI-compliant).
|
|
||||||
We define MUSL_LIBC in CXXFLAGS to skip the wrong #else implementation.
|
|
||||||
|
|
||||||
--- snapper/AppUtil.cc 2019-01-26 13:29:29.110490961 +0200
|
|
||||||
+++ snapper/AppUtil.cc 2019-01-26 13:29:51.324648467 +0200
|
|
||||||
@@ -223,7 +223,7 @@ namespace snapper
|
|
||||||
string
|
|
||||||
stringerror(int errnum)
|
|
||||||
{
|
|
||||||
-#if (_POSIX_C_SOURCE >= 200112L) && ! _GNU_SOURCE
|
|
||||||
+#if (_POSIX_C_SOURCE >= 200112L) && ! _GNU_SOURCE || MUSL_LIBC
|
|
||||||
char buf1[100];
|
|
||||||
if (strerror_r(errnum, buf1, sizeof(buf1) - 1) == 0)
|
|
||||||
return string(buf1);
|
|
@ -1,12 +0,0 @@
|
|||||||
Need to include unistd.h to define uid_t for musl libc.
|
|
||||||
|
|
||||||
--- snapper/Snapshot.h 2015-02-18 18:54:03.000000000 +0100
|
|
||||||
+++ snapper/Snapshot.h 2015-08-30 10:33:14.197150669 +0200
|
|
||||||
@@ -25,6 +25,7 @@
|
|
||||||
|
|
||||||
|
|
||||||
#include <time.h>
|
|
||||||
+#include <unistd.h>
|
|
||||||
#include <string>
|
|
||||||
#include <list>
|
|
||||||
#include <map>
|
|
27
srcpkgs/snapper/patches/musl_u_int-type.patch
Normal file
27
srcpkgs/snapper/patches/musl_u_int-type.patch
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
From 7ddd58ee5e6b7c3a8df3086ff5a6d17d19362761 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Nathan Owens <ndowens04@gmail.com>
|
||||||
|
Date: Wed, 18 Dec 2019 18:35:55 -0600
|
||||||
|
Subject: [PATCH] musl-_u_int-types
|
||||||
|
|
||||||
|
Signed-off-by: Nathan Owens <ndowens04@gmail.com>
|
||||||
|
---
|
||||||
|
client/utils/JsonFormatter.h | 3 +++
|
||||||
|
1 file changed, 3 insertions(+)
|
||||||
|
|
||||||
|
diff --git client/utils/JsonFormatter.h client/utils/JsonFormatter.h
|
||||||
|
index 79f7672..501b77d 100644
|
||||||
|
--- client/utils/JsonFormatter.h
|
||||||
|
+++ client/utils/JsonFormatter.h
|
||||||
|
@@ -25,6 +25,9 @@
|
||||||
|
#include <string>
|
||||||
|
#include <vector>
|
||||||
|
#include <utility>
|
||||||
|
+#ifndef __GLIBC__
|
||||||
|
+#include <sys/types.h>
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
namespace snapper
|
||||||
|
{
|
||||||
|
--
|
||||||
|
2.24.1
|
||||||
|
|
@ -1,6 +1,6 @@
|
|||||||
# Template file for 'snapper'
|
# Template file for 'snapper'
|
||||||
pkgname=snapper
|
pkgname=snapper
|
||||||
version=0.8.5
|
version=0.8.7
|
||||||
revision=1
|
revision=1
|
||||||
build_style=gnu-configure
|
build_style=gnu-configure
|
||||||
configure_args="--disable-zypp --with-conf=/etc/conf.d"
|
configure_args="--disable-zypp --with-conf=/etc/conf.d"
|
||||||
@ -14,7 +14,7 @@ maintainer="Orphaned <orphan@voidlinux.org>"
|
|||||||
license="GPL-2.0-only"
|
license="GPL-2.0-only"
|
||||||
homepage="http://snapper.io"
|
homepage="http://snapper.io"
|
||||||
distfiles="https://github.com/openSUSE/snapper/archive/v${version}.tar.gz"
|
distfiles="https://github.com/openSUSE/snapper/archive/v${version}.tar.gz"
|
||||||
checksum=f7269eeca6e400609d5fbf6b2bef1594e2483a6a0b09b10174fd582b8b13ead2
|
checksum=13c56586b01ece9ca3d1ac19a9e7384385662b7600788f56c9940919ae6f1467
|
||||||
lib32disabled=yes
|
lib32disabled=yes
|
||||||
|
|
||||||
case "$XBPS_TARGET_MACHINE" in
|
case "$XBPS_TARGET_MACHINE" in
|
||||||
@ -29,9 +29,6 @@ pre_configure() {
|
|||||||
# fix config location in cron scripts
|
# fix config location in cron scripts
|
||||||
sed -i -e 's@/etc/sysconfig/@/etc/conf.d/@g' scripts/snapper-{daily,hourly}
|
sed -i -e 's@/etc/sysconfig/@/etc/conf.d/@g' scripts/snapper-{daily,hourly}
|
||||||
|
|
||||||
sed -i -e 's@lboost_thread-mt@lboost_thread@g' snapper/Makefile.am
|
|
||||||
sed -i -e 's@lboost_system-mt@lboost_system@g' snapper/Makefile.am
|
|
||||||
|
|
||||||
# fix pam plugin install location
|
# fix pam plugin install location
|
||||||
sed -i -e 's@shell echo /@shell echo /usr/@g' pam/Makefile.am
|
sed -i -e 's@shell echo /@shell echo /usr/@g' pam/Makefile.am
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user