Import of pkgsrc-2015Q1

This commit is contained in:
2016-01-21 23:40:00 +01:00
committed by sambuc
parent 9a8c06dafb
commit 4af1cdf7a9
25114 changed files with 870539 additions and 795424 deletions
@@ -0,0 +1,49 @@
$NetBSD: patch-config_amanda_tape.m4,v 1.1 2015/03/27 23:45:29 gdt Exp $
This patch is from upstream. It resolves a failure to compile in tape
support; without including sys/types.h and sys/time.h, sys/tape.h
generates an error on NetBSD.
--- config/amanda/tape.m4.orig 2012-02-21 11:36:49.000000000 +0000
+++ config/amanda/tape.m4
@@ -34,6 +34,10 @@ AC_DEFUN([AMANDA_TAPE_DEVICE], [
# check for MTIOCTOP, an indicator of POSIX tape support
AC_CACHE_CHECK([for MTIOCTOP], amanda_cv_HAVE_MTIOCTOP,[
AC_TRY_COMPILE([
+#include <sys/types.h>
+#ifdef HAVE_SYS_TIME_H
+# include <sys/time.h>
+# endif
#ifdef HAVE_SYS_TAPE_H
# include <sys/tape.h>
#endif
@@ -66,6 +70,9 @@ AC_DEFUN([AMANDA_TAPE_DEVICE], [
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#include <stdio.h>
#include <sys/types.h>
+#ifdef HAVE_SYS_TIME_H
+# include <sys/time.h>
+#endif
#include <sys/mtio.h>
]], [[
struct mtget buf;
@@ -85,6 +92,9 @@ AC_DEFUN([AMANDA_TAPE_DEVICE], [
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#include <stdio.h>
#include <sys/types.h>
+#ifdef HAVE_SYS_TIME_H
+# include <sys/time.h>
+#endif
#include <sys/mtio.h>
]], [[
struct mtget buf;
@@ -139,6 +149,9 @@ AC_DEFUN([AMANDA_TAPE_DEVICE], [
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
#include <stdio.h>
#include <sys/types.h>
+#ifdef HAVE_SYS_TIME_H
+# include <sys/time.h>
+#endif
#include <sys/mtio.h>
]], [[
struct mtget buf;
@@ -0,0 +1,27 @@
$NetBSD: patch-device-src_device.c,v 1.1 2015/03/27 23:45:29 gdt Exp $
This patch is from upstream, to improve error reporting when amanda is
configured without tape drive support and one tries to use a tape.
--- device-src/device.c.orig 2012-02-21 11:36:44.000000000 +0000
+++ device-src/device.c
@@ -423,17 +423,13 @@ handle_device_regex(const char * user_na
regfree(&regex);
return FALSE;
} else if (reg_result == REG_NOMATCH) {
+ *driver_name = stralloc("tape");
+ *device = stralloc(user_name);
#ifdef WANT_TAPE_DEVICE
g_warning(
"\"%s\" uses deprecated device naming convention; \n"
"using \"tape:%s\" instead.\n",
user_name, user_name);
- *driver_name = stralloc("tape");
- *device = stralloc(user_name);
-#else /* !WANT_TAPE_DEVICE */
- *errmsg = newvstrallocf(*errmsg, "\"%s\" is not a valid device name.\n", user_name);
- regfree(&regex);
- return FALSE;
#endif /* WANT_TAPE_DEVICE */
} else {
*driver_name = find_regex_substring(user_name, pmatch[1]);
@@ -0,0 +1,21 @@
$NetBSD: patch-ndmp-src_ndmp2__xdr.c,v 1.1 2014/07/28 15:53:44 jperkin Exp $
Compat for SunOS 64-bit.
--- ndmp-src/ndmp2_xdr.c.orig 2012-02-21 11:38:58.000000000 +0000
+++ ndmp-src/ndmp2_xdr.c
@@ -3,6 +3,14 @@
* It was generated using rpcgen.
*/
+#ifdef __sun
+#ifndef IXDR_PUT_U_LONG
+#define IXDR_PUT_U_LONG IXDR_PUT_U_INT32
+#endif
+#ifndef IXDR_GET_U_LONG
+#define IXDR_GET_U_LONG IXDR_GET_U_INT32
+#endif
+#endif
#include "ndmp2.h"
#ifndef NDMOS_OPTION_NO_NDMP2
#define ndmp2_u_quad unsigned long long
@@ -0,0 +1,21 @@
$NetBSD: patch-ndmp-src_ndmp3__xdr.c,v 1.1 2014/07/28 15:53:44 jperkin Exp $
Compat for SunOS 64-bit.
--- ndmp-src/ndmp3_xdr.c.orig 2012-02-21 11:38:58.000000000 +0000
+++ ndmp-src/ndmp3_xdr.c
@@ -3,6 +3,14 @@
* It was generated using rpcgen.
*/
+#ifdef __sun
+#ifndef IXDR_PUT_U_LONG
+#define IXDR_PUT_U_LONG IXDR_PUT_U_INT32
+#endif
+#ifndef IXDR_GET_U_LONG
+#define IXDR_GET_U_LONG IXDR_GET_U_INT32
+#endif
+#endif
#include "ndmp3.h"
#ifndef NDMOS_OPTION_NO_NDMP3
#define ndmp3_u_quad unsigned long long
@@ -0,0 +1,21 @@
$NetBSD: patch-ndmp-src_ndmp4__xdr.c,v 1.1 2014/07/28 15:53:44 jperkin Exp $
Compat for SunOS 64-bit.
--- ndmp-src/ndmp4_xdr.c.orig 2012-02-21 11:38:58.000000000 +0000
+++ ndmp-src/ndmp4_xdr.c
@@ -3,6 +3,14 @@
* It was generated using rpcgen.
*/
+#ifdef __sun
+#ifndef IXDR_PUT_U_LONG
+#define IXDR_PUT_U_LONG IXDR_PUT_U_INT32
+#endif
+#ifndef IXDR_GET_U_LONG
+#define IXDR_GET_U_LONG IXDR_GET_U_INT32
+#endif
+#endif
#include "ndmp4.h"
#ifndef NDMOS_OPTION_NO_NDMP4
#define ndmp4_u_quad unsigned long long
@@ -0,0 +1,21 @@
$NetBSD: patch-perl_Amanda_Report_human.pm,v 1.1 2015/03/27 23:45:29 gdt Exp $
On NetBSD 5 amd64, perl coredumps because of this call (or some
component of it), leading to not getting a report. For now, comment
it out to get most of the report. This has not yet been reported
upstream.
--- perl/Amanda/Report/human.pm.orig 2012-02-21 11:36:47.000000000 +0000
+++ perl/Amanda/Report/human.pm
@@ -319,7 +319,10 @@ sub print_human_amreport
$self->calculate_stats();
## print the basic info header
- $self->print_header();
+ # The next line crashes perl 5.20 on NetBSD 5 amd64. Hence it is
+ # commented out as reports without the header are better than no
+ # reports.
+ #$self->print_header();
## print out statements about past and predicted tape usage
$self->output_tapeinfo();