Import of pkgsrc-2014Q1

This commit is contained in:
2014-04-17 16:38:45 +02:00
parent 785076ae39
commit 9a8c06dafb
19365 changed files with 828089 additions and 278039 deletions

View File

@@ -1,13 +1,22 @@
$NetBSD: patch-Makefile,v 1.3 2012/09/04 13:43:15 wiz Exp $
$NetBSD: patch-Makefile,v 1.5 2014/03/19 13:15:13 gdt Exp $
Remove CFLAGS override (set from pkgsrc Makefile).
Pass PYTHON through to configure.
--- Makefile.orig 2011-06-09 03:24:45.000000000 +0000
--- Makefile.orig 2013-12-10 01:30:45.000000000 +0000
+++ Makefile
@@ -1,5 +1,5 @@
OS:=$(shell uname | sed 's/[-_].*//')
-CFLAGS:=-Wall -O2 -Werror $(PYINCLUDE)
+CFLAGS+=-Wall -O2 -Werror $(PYINCLUDE)
-CFLAGS := -Wall -O2 -Werror $(PYINCLUDE) $(CFLAGS)
+CFLAGS := -Wall -O2 -Werror -Wno-unknown-pragmas $(PYINCLUDE) $(CFLAGS)
SOEXT:=.so
ifeq ($(OS),CYGWIN)
@@ -67,7 +67,7 @@ install: all
config/config.h: config/Makefile config/configure config/configure.inc \
$(wildcard config/*.in)
- cd config && $(MAKE) config.h
+ cd config && $(MAKE) PYTHON=$(PYTHON) config.h
lib/bup/_helpers$(SOEXT): \
config/config.h \

View File

@@ -1,25 +1,15 @@
$NetBSD: patch-config_configure,v 1.1 2012/09/04 13:43:15 wiz Exp $
$NetBSD: patch-config_configure,v 1.2 2013/12/31 11:03:12 wiz Exp $
Use PYTHON from environment.
Do not check for utimensat. It is found on NetBSD even though unusable
for now (20120827).
Use PYTHON passed through from Makefile.
--- config/configure.orig 2011-06-09 03:24:45.000000000 +0000
--- config/configure.orig 2013-11-11 08:52:33.000000000 +0000
+++ config/configure
@@ -30,7 +30,7 @@ expr "$MAKE_VERSION" '>=' '3.81' || AC_F
TLOG " ok"
TLOGN "checking the python"
-PYTHON=`acLookFor python`
+[ -n "$PYTHON" ] || PYTHON=`acLookFor python`
if [ -z "$PYTHON" ]; then
AC_FAIL " Cannot find python";
@@ -42,7 +42,7 @@ if [ -z "$MAKE_VERSION" ]; then
fi
@@ -59,7 +59,6 @@ AC_CHECK_HEADERS unistd.h
AC_CHECK_HEADERS linux/fs.h
AC_CHECK_HEADERS sys/ioctl.h
expr "$MAKE_VERSION" '>=' '3.81' || AC_FAIL "ERROR: $MAKE must be >= version 3.81"
-AC_CHECK_FUNCS utimensat
AC_CHECK_FUNCS utimes
AC_CHECK_FUNCS lutimes
-if test -z "$(bup_find_prog python '')"; then
+if test -z "$(bup_find_prog python "$PYTHON")"; then
AC_FAIL "ERROR: unable to find python"
fi

View File

@@ -0,0 +1,51 @@
$NetBSD: patch-lib_bup___helpers.c,v 1.2 2014/03/19 17:50:00 gdt Exp $
First and third hunks are from upstream.
Second hunk is to work around broken utimensat in NetBSD 6.
Should be applied upstream.
--- lib/bup/_helpers.c.orig 2013-12-10 01:30:45.000000000 +0000
+++ lib/bup/_helpers.c
@@ -96,6 +96,8 @@ static void unpythonize_argv(void)
#endif // not __WIN32__ or __CYGWIN__
+// At the moment any code that calls INTGER_TO_PY() will have to
+// disable -Wtautological-compare for clang. See below.
static PyObject *selftest(PyObject *self, PyObject *args)
{
@@ -763,6 +765,14 @@ static PyObject *bup_set_linux_file_attr
#endif /* def BUP_HAVE_FILE_ATTRS */
+/*
+ * Check for defective UTIMENSAT support (NetBSD 6), and if so,
+ * pretend we don't have it.
+ */
+#if !defined(AT_FDCWD) || !defined(AT_SYMLINK_NOFOLLOW)
+#undef HAVE_UTIMENSAT
+#endif
+
#if defined(HAVE_UTIMENSAT) || defined(HAVE_FUTIMES) || defined(HAVE_LUTIMES)
static int bup_parse_xutime_args(char **path,
@@ -990,6 +1000,9 @@ static int normalize_timespec_values(con
(((x) >= 0) ? PyLong_FromUnsignedLongLong(x) : PyLong_FromLongLong(x))
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wtautological-compare" // For INTEGER_TO_PY().
+
static PyObject *stat_struct_to_py(const struct stat *st,
const char *filename,
int fd)
@@ -1028,6 +1041,7 @@ static PyObject *stat_struct_to_py(const
(long) ctime_ns);
}
+#pragma clang diagnostic pop // ignored "-Wtautological-compare"
static PyObject *bup_stat(PyObject *self, PyObject *args)
{

View File

@@ -1,27 +0,0 @@
$NetBSD: patch-lib_bup_helpers.py,v 1.1 2012/09/04 13:43:15 wiz Exp $
Survive empty GECOS name fields.
Reported-by: Alper Kanat
Tested-by: Michael Witten
Signed-off-by: Michael Witten
---
lib/bup/helpers.py | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
--- lib/bup/helpers.py.orig 2011-06-09 03:24:45.000000000 +0000
+++ lib/bup/helpers.py
@@ -231,9 +231,11 @@ def userfullname():
if not _userfullname:
uid = os.getuid()
try:
- _userfullname = pwd.getpwuid(uid)[4].split(',')[0]
- except KeyError:
- _userfullname = 'user%d' % uid
+ entry = pwd.getpwuid(uid)
+ _userfullname = entry[4].split(',')[0] or entry[0]
+ finally:
+ if not _userfullname:
+ _userfullname = 'user %d' % uid
return _userfullname