summaryrefslogtreecommitdiff
path: root/sysutils
diff options
context:
space:
mode:
authorthorpej <thorpej>1997-11-13 08:17:23 +0000
committerthorpej <thorpej>1997-11-13 08:17:23 +0000
commit6996e899f4cdbcd29b3d6fb6e3ede60e17ebbb43 (patch)
tree0df7b71d00348807824be7026678c24631abb107 /sysutils
parent2d4019bdb61ab5a5088c24840777a635bea858ac (diff)
downloadpkgsrc-6996e899f4cdbcd29b3d6fb6e3ede60e17ebbb43.tar.gz
Port to NetBSD 1.3 and remove the automatic symlink of the real
CD-R device to /dev/sgx.
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/cdrecord/Makefile10
-rw-r--r--sysutils/cdrecord/patches/patch-ab36
-rw-r--r--sysutils/cdrecord/patches/patch-ac58
-rw-r--r--sysutils/cdrecord/pkg/PLIST7
4 files changed, 101 insertions, 10 deletions
diff --git a/sysutils/cdrecord/Makefile b/sysutils/cdrecord/Makefile
index 79f78633944..6783501777d 100644
--- a/sysutils/cdrecord/Makefile
+++ b/sysutils/cdrecord/Makefile
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.2 1997/11/13 07:35:37 thorpej Exp $
+# $NetBSD: Makefile,v 1.3 1997/11/13 08:17:23 thorpej Exp $
#
# New ports collection makefile for: cdrecord
# Version required: 1.5
@@ -20,13 +20,13 @@ MAN1= cdrecord.1
USE_GMAKE= yes
do-build:
- @cd ${WRKSRC}/lib && ../Gmake
- @cd ${WRKSRC}/cdrecord && ../Gmake
+ @cd ${WRKSRC}/lib && ../Gmake PREFIX=${PREFIX}
+ @cd ${WRKSRC}/cdrecord && ../Gmake PREFIX=${PREFIX}
do-install:
- @${INSTALL_PROGRAM} ${WRKSRC}/cdrecord/OBJ/i386-freebsd-cc/cdrecord \
+ @${INSTALL_PROGRAM} ${WRKSRC}/cdrecord/OBJ/i386-netbsd-cc/cdrecord \
${PREFIX}/bin
@${INSTALL_MAN} ${WRKSRC}/cdrecord/cdrecord.1 ${PREFIX}/man/man1
- @cd /dev && ln -sf /dev/rworm0.ctl sgx
+# @cd /dev && ln -sf /dev/rworm0.ctl sgx
.include <bsd.port.mk>
diff --git a/sysutils/cdrecord/patches/patch-ab b/sysutils/cdrecord/patches/patch-ab
new file mode 100644
index 00000000000..8691b3a726b
--- /dev/null
+++ b/sysutils/cdrecord/patches/patch-ab
@@ -0,0 +1,36 @@
+*** DEFAULTS/Defaults.netbsd.orig Wed Nov 12 23:52:33 1997
+--- DEFAULTS/Defaults.netbsd Wed Nov 12 23:55:30 1997
+***************
+*** 19,25 ****
+ CWARNOPTS=
+
+ DEFINCDIRS= $(SRCROOT)/include
+! LDPATH= -L/opt/schily/lib
+ #RUNPATH= -R /opt/schily/lib -R $(OLIBSDIR) Will probably not work
+
+ ###########################################################################
+--- 19,25 ----
+ CWARNOPTS=
+
+ DEFINCDIRS= $(SRCROOT)/include
+! LDPATH= -L$(SRCROOT)/lib
+ #RUNPATH= -R /opt/schily/lib -R $(OLIBSDIR) Will probably not work
+
+ ###########################################################################
+***************
+*** 27,33 ****
+ # Installation config stuff
+ #
+ ###########################################################################
+! INS_BASE= /opt/schily
+ INS_KBASE= /
+ #
+ DEFUMASK= 002
+--- 27,33 ----
+ # Installation config stuff
+ #
+ ###########################################################################
+! INS_BASE= $(PREFIX)
+ INS_KBASE= /
+ #
+ DEFUMASK= 002
diff --git a/sysutils/cdrecord/patches/patch-ac b/sysutils/cdrecord/patches/patch-ac
new file mode 100644
index 00000000000..a88383441db
--- /dev/null
+++ b/sysutils/cdrecord/patches/patch-ac
@@ -0,0 +1,58 @@
+*** cdrecord/scsi-bsd.c.orig Wed Nov 12 23:41:37 1997
+--- cdrecord/scsi-bsd.c Wed Nov 12 23:46:55 1997
+***************
+*** 42,47 ****
+--- 42,62 ----
+ /*#define MAX_DMA_BSD (32*1024)*/
+ #define MAX_DMA_BSD (64*1024) /* Check if this is not too big */
+
++ #if defined(__NetBSD__) && defined(TYPE_ATAPI)
++ /*
++ * NetBSD 1.3 has a merged SCSI/ATAPI system, so this structure
++ * is slightly different.
++ */
++ #define ADDR_ISSCSI(a) ((a).type == TYPE_SCSI)
++ #define ADDR_SCBUS(a) (a).addr.scsi.scbus
++ #define ADDR_TARGET(a) (a).addr.scsi.target
++ #define ADDR_LUN(a) (a).addr.scsi.lun
++ #else
++ #define ADDR_ISSCSI(a) (1)
++ #define ADDR_SCBUS(a) (a).addr.scbus
++ #define ADDR_TARGET(a) (a).addr.target
++ #define ADDR_LUN(a) (a).addr.lun
++ #endif /* __NetBSD__ && TYPE_ATAPI */
+
+ LOCAL int scsi_send __PR((int f, struct scg_cmd *sp));
+ LOCAL int scsi_setup __PR((int f));
+***************
+*** 127,139 ****
+ errmsg("Cannot get SCSI addr.\n");
+ return (-1);
+ }
+- if (debug)
+- printf("Bus: %d Target: %d Lun: %d\n",
+- saddr.scbus, saddr.target, saddr.lun);
+
+! Bus = saddr.scbus;
+! Target = saddr.target;
+! Lun = saddr.lun;
+
+ if (Bus >= MAX_SCG || Target >= 8 || Lun >= 8)
+ return (-1);
+--- 142,157 ----
+ errmsg("Cannot get SCSI addr.\n");
+ return (-1);
+ }
+
+! if (ADDR_ISSCSI(saddr) == 0)
+! return (-1);
+!
+! Bus = ADDR_SCBUS(saddr);
+! Target = ADDR_TARGET(saddr);
+! Lun = ADDR_LUN(saddr);
+!
+! if (debug)
+! printf("Bus: %d Target: %d Lun: %d\n", Bus, Target, Lun);
+
+ if (Bus >= MAX_SCG || Target >= 8 || Lun >= 8)
+ return (-1);
diff --git a/sysutils/cdrecord/pkg/PLIST b/sysutils/cdrecord/pkg/PLIST
index c7337767539..7d72ead582a 100644
--- a/sysutils/cdrecord/pkg/PLIST
+++ b/sysutils/cdrecord/pkg/PLIST
@@ -1,6 +1,3 @@
-@comment $NetBSD: PLIST,v 1.2 1997/11/13 07:35:38 thorpej Exp $
+@comment $NetBSD: PLIST,v 1.3 1997/11/13 08:17:27 thorpej Exp $
bin/cdrecord
-man/man1/cdrecord.1.gz
-@cd /dev
-@exec ln -sf /dev/rworm0.ctl sgx
-@unexec rm -f sgx
+man/man1/cdrecord.1