pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/archivers/pax/files Fix build on Cygwin.
details: https://anonhg.NetBSD.org/pkgsrc/rev/aa04321953c0
branches: trunk
changeset: 622125:aa04321953c0
user: ryoon <ryoon%pkgsrc.org@localhost>
date: Fri Jul 26 12:37:41 2013 +0000
description:
Fix build on Cygwin.
__dev32_t is removed since 1.7.19 of cygwin.
Like http://mail-index.netbsd.org/source-changes/2013/06/14/msg044776.html .
diffstat:
archivers/pax/files/pack_dev.c | 48 +++++++++++++++++++++---------------------
archivers/pax/files/pack_dev.h | 9 +------
2 files changed, 26 insertions(+), 31 deletions(-)
diffs (170 lines):
diff -r d392cfc16ad3 -r aa04321953c0 archivers/pax/files/pack_dev.c
--- a/archivers/pax/files/pack_dev.c Fri Jul 26 11:47:57 2013 +0000
+++ b/archivers/pax/files/pack_dev.c Fri Jul 26 12:37:41 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pack_dev.c,v 1.4 2008/04/29 05:46:09 martin Exp $ */
+/* $NetBSD: pack_dev.c,v 1.5 2013/07/26 12:37:41 ryoon Exp $ */
/*-
* Copyright (c) 1998, 2001 The NetBSD Foundation, Inc.
@@ -41,7 +41,7 @@
#include <sys/cdefs.h>
#endif
#if !defined(lint)
-__RCSID("$NetBSD: pack_dev.c,v 1.4 2008/04/29 05:46:09 martin Exp $");
+__RCSID("$NetBSD: pack_dev.c,v 1.5 2013/07/26 12:37:41 ryoon Exp $");
#endif /* not lint */
#if HAVE_SYS_TYPES_H
@@ -84,10 +84,10 @@
static const char tooManyFields[] = "too many fields for format";
/* exported */
-portdev_t
+dev_t
pack_native(int n, u_long numbers[], const char **error)
{
- portdev_t dev = 0;
+ dev_t dev = 0;
if (n == 2) {
dev = TODEV(numbers[0], numbers[1]);
@@ -101,10 +101,10 @@
}
-static portdev_t
+static dev_t
pack_netbsd(int n, u_long numbers[], const char **error)
{
- portdev_t dev = 0;
+ dev_t dev = 0;
if (n == 2) {
dev = makedev_netbsd(numbers[0], numbers[1]);
@@ -120,13 +120,13 @@
#define major_freebsd(x) ((int32_t)(((x) & 0x0000ff00) >> 8))
#define minor_freebsd(x) ((int32_t)(((x) & 0xffff00ff) >> 0))
-#define makedev_freebsd(x,y) ((portdev_t)((((x) << 8) & 0x0000ff00) | \
+#define makedev_freebsd(x,y) ((dev_t)((((x) << 8) & 0x0000ff00) | \
(((y) << 0) & 0xffff00ff)))
-static portdev_t
+static dev_t
pack_freebsd(int n, u_long numbers[], const char **error)
{
- portdev_t dev = 0;
+ dev_t dev = 0;
if (n == 2) {
dev = makedev_freebsd(numbers[0], numbers[1]);
@@ -142,13 +142,13 @@
#define major_8_8(x) ((int32_t)(((x) & 0x0000ff00) >> 8))
#define minor_8_8(x) ((int32_t)(((x) & 0x000000ff) >> 0))
-#define makedev_8_8(x,y) ((portdev_t)((((x) << 8) & 0x0000ff00) | \
+#define makedev_8_8(x,y) ((dev_t)((((x) << 8) & 0x0000ff00) | \
(((y) << 0) & 0x000000ff)))
-static portdev_t
+static dev_t
pack_8_8(int n, u_long numbers[], const char **error)
{
- portdev_t dev = 0;
+ dev_t dev = 0;
if (n == 2) {
dev = makedev_8_8(numbers[0], numbers[1]);
@@ -164,13 +164,13 @@
#define major_12_20(x) ((int32_t)(((x) & 0xfff00000) >> 20))
#define minor_12_20(x) ((int32_t)(((x) & 0x000fffff) >> 0))
-#define makedev_12_20(x,y) ((portdev_t)((((x) << 20) & 0xfff00000) | \
+#define makedev_12_20(x,y) ((dev_t)((((x) << 20) & 0xfff00000) | \
(((y) << 0) & 0x000fffff)))
-static portdev_t
+static dev_t
pack_12_20(int n, u_long numbers[], const char **error)
{
- portdev_t dev = 0;
+ dev_t dev = 0;
if (n == 2) {
dev = makedev_12_20(numbers[0], numbers[1]);
@@ -186,13 +186,13 @@
#define major_14_18(x) ((int32_t)(((x) & 0xfffc0000) >> 18))
#define minor_14_18(x) ((int32_t)(((x) & 0x0003ffff) >> 0))
-#define makedev_14_18(x,y) ((portdev_t)((((x) << 18) & 0xfffc0000) | \
+#define makedev_14_18(x,y) ((dev_t)((((x) << 18) & 0xfffc0000) | \
(((y) << 0) & 0x0003ffff)))
-static portdev_t
+static dev_t
pack_14_18(int n, u_long numbers[], const char **error)
{
- portdev_t dev = 0;
+ dev_t dev = 0;
if (n == 2) {
dev = makedev_14_18(numbers[0], numbers[1]);
@@ -208,13 +208,13 @@
#define major_8_24(x) ((int32_t)(((x) & 0xff000000) >> 24))
#define minor_8_24(x) ((int32_t)(((x) & 0x00ffffff) >> 0))
-#define makedev_8_24(x,y) ((portdev_t)((((x) << 24) & 0xff000000) | \
+#define makedev_8_24(x,y) ((dev_t)((((x) << 24) & 0xff000000) | \
(((y) << 0) & 0x00ffffff)))
-static portdev_t
+static dev_t
pack_8_24(int n, u_long numbers[], const char **error)
{
- portdev_t dev = 0;
+ dev_t dev = 0;
if (n == 2) {
dev = makedev_8_24(numbers[0], numbers[1]);
@@ -231,14 +231,14 @@
#define major_12_12_8(x) ((int32_t)(((x) & 0xfff00000) >> 20))
#define unit_12_12_8(x) ((int32_t)(((x) & 0x000fff00) >> 8))
#define subunit_12_12_8(x) ((int32_t)(((x) & 0x000000ff) >> 0))
-#define makedev_12_12_8(x,y,z) ((portdev_t)((((x) << 20) & 0xfff00000) | \
+#define makedev_12_12_8(x,y,z) ((dev_t)((((x) << 20) & 0xfff00000) | \
(((y) << 8) & 0x000fff00) | \
(((z) << 0) & 0x000000ff)))
-static portdev_t
+static dev_t
pack_bsdos(int n, u_long numbers[], const char **error)
{
- portdev_t dev = 0;
+ dev_t dev = 0;
if (n == 2) {
dev = makedev_12_20(numbers[0], numbers[1]);
diff -r d392cfc16ad3 -r aa04321953c0 archivers/pax/files/pack_dev.h
--- a/archivers/pax/files/pack_dev.h Fri Jul 26 11:47:57 2013 +0000
+++ b/archivers/pax/files/pack_dev.h Fri Jul 26 12:37:41 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pack_dev.h,v 1.3 2008/04/29 05:46:09 martin Exp $ */
+/* $NetBSD: pack_dev.h,v 1.4 2013/07/26 12:37:41 ryoon Exp $ */
/*-
* Copyright (c) 1998, 2001 The NetBSD Foundation, Inc.
@@ -32,12 +32,7 @@
#ifndef _PACK_DEV_H
#define _PACK_DEV_H
-#ifdef __CYGWIN__
-typedef __dev32_t portdev_t;
-#else
-typedef dev_t portdev_t;
-#endif
-typedef portdev_t pack_t(int, u_long [], const char **);
+typedef dev_t pack_t(int, u_long [], const char **);
pack_t *pack_find(const char *);
pack_t pack_native;
Home |
Main Index |
Thread Index |
Old Index