summaryrefslogtreecommitdiffstats
path: root/sysutils
diff options
context:
space:
mode:
authornetchild <netchild@FreeBSD.org>2003-01-02 15:07:43 +0000
committernetchild <netchild@FreeBSD.org>2003-01-02 15:07:43 +0000
commit204aa6344f4ed887d1fa64c0e44f994fc8ced9db (patch)
tree0dd8ae855d63148102cb9b65ca97b0757c2f8ee5 /sysutils
parent2d06637d3146a986d9c6c0d8aa5d92751b3c4168 (diff)
downloadFreeBSD-ports-204aa6344f4ed887d1fa64c0e44f994fc8ced9db.zip
FreeBSD-ports-204aa6344f4ed887d1fa64c0e44f994fc8ced9db.tar.gz
From the submitter:
Sun format is a util for formatting/partitioning/analysis/repairing of SCSI disks. While formatting and partitioning currently is only usefule on big- endian systems in order to create Sun disk labels, analysis and repairing works on either endian and are very useful to remap defect blocks when AWRE/ARRE fail for some reason. Tested on i386 and sparc64, respawned a disk here. Submitted by: marius@alchemy.franken.de
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/Makefile1
-rw-r--r--sysutils/sformat/Makefile42
-rw-r--r--sysutils/sformat/distinfo1
-rw-r--r--sysutils/sformat/files/patch-RULES::i386-freebsd-cc.rul31
-rw-r--r--sysutils/sformat/files/patch-TARGETS::Targetdirs9
-rw-r--r--sysutils/sformat/files/patch-sformat::datio.c15
-rw-r--r--sysutils/sformat/files/patch-sformat::fmt.c11
-rw-r--r--sysutils/sformat/files/patch-sformat::sformat.111
-rw-r--r--sysutils/sformat/pkg-comment1
-rw-r--r--sysutils/sformat/pkg-descr27
-rw-r--r--sysutils/sformat/pkg-plist3
11 files changed, 152 insertions, 0 deletions
diff --git a/sysutils/Makefile b/sysutils/Makefile
index 93c062c..5692c8c 100644
--- a/sysutils/Makefile
+++ b/sysutils/Makefile
@@ -203,6 +203,7 @@
SUBDIR += service-config
SUBDIR += setcdboot
SUBDIR += setquota
+ SUBDIR += sformat
SUBDIR += shlock
SUBDIR += sjog
SUBDIR += skill
diff --git a/sysutils/sformat/Makefile b/sysutils/sformat/Makefile
new file mode 100644
index 0000000..268e90a
--- /dev/null
+++ b/sysutils/sformat/Makefile
@@ -0,0 +1,42 @@
+# New ports collection makefile for: sformat
+# Date created: 16 December 2002
+# Whom: marius@alchemy.franken.de
+#
+# $FreeBSD$
+#
+
+PORTNAME= sformat
+PORTVERSION= 3.5
+CATEGORIES= sysutils
+MASTER_SITES= ftp://ftp.zeist.de/pub/distfiles/ \
+ ftp://ftp.berlios.de/pub/sformat/
+
+MAINTAINER= marius@alchemy.franken.de
+
+USE_GMAKE= yes
+USE_REINPLACE= yes
+
+MAN1= sformat.1
+
+MAKE_ENV= COPTX="-DBSD_SCSI_SENSE_BUG"
+
+post-extract:
+.if ${MACHINE_ARCH} != "i386"
+ @${LN} -s ${WRKSRC}/RULES/i386-freebsd-cc.rul \
+ ${WRKSRC}/RULES/${MACHINE_ARCH}-freebsd-cc.rul
+.endif
+
+post-patch:
+.for i in datio.c sformat.1
+ @${REINPLACE_CMD} -i "" -e 's:%%DATADIR%%:${DATADIR}:g;' \
+ ${WRKSRC}/sformat/${i}
+.endfor
+
+do-install:
+ @${INSTALL_PROGRAM} ${WRKSRC}/sformat/OBJ/${ARCH}-freebsd-cc/sformat \
+ ${PREFIX}/bin
+ @${MKDIR} ${DATADIR}
+ @${INSTALL_DATA} ${WRKSRC}/sformat/sformat.dat ${DATADIR}
+ @${INSTALL_MAN} ${WRKSRC}/sformat/sformat.1 ${PREFIX}/man/man1
+
+.include <bsd.port.mk>
diff --git a/sysutils/sformat/distinfo b/sysutils/sformat/distinfo
new file mode 100644
index 0000000..4693b13
--- /dev/null
+++ b/sysutils/sformat/distinfo
@@ -0,0 +1 @@
+MD5 (sformat-3.5.tar.gz) = 10317f96dfd5262a7813350034131695
diff --git a/sysutils/sformat/files/patch-RULES::i386-freebsd-cc.rul b/sysutils/sformat/files/patch-RULES::i386-freebsd-cc.rul
new file mode 100644
index 0000000..5b94b84
--- /dev/null
+++ b/sysutils/sformat/files/patch-RULES::i386-freebsd-cc.rul
@@ -0,0 +1,31 @@
+--- RULES/i386-freebsd-cc.rul.orig Tue Oct 15 22:43:39 2002
++++ RULES/i386-freebsd-cc.rul Sun Oct 27 19:59:00 2002
+@@ -24,7 +24,8 @@
+ ###########################################################################
+
+ CPPFLAGS= $(CPPOPTS) $(CPPOPTX)
+-CFLAGS= $(COPTS) $(CWARNOPTS) $(COPTOPT) $(COPTX)
++XCFLAGS:= $(CFLAGS)
++CFLAGS= $(COPTS) $(CWARNOPTS) $(XCFLAGS) $(COPTX)
+
+ CPPOPTS= -I. -I$(ARCHDIR) -I$(OINCSDIR) $(INCDIRS:%=-I%) $(OSDEFS)
+ COPTS=
+@@ -57,14 +58,13 @@
+
+ FLOAT_OPTIONS=
+
+-CC= @echo " ==> COMPILING \"$@\""; gcc
+-LDCC= @echo " ==> LINKING \"$@\""; gcc
+-DYNLD= @echo " ==> LINKING dynamic library \"$@\""; gcc
+-RANLIB= @echo " ==> RANDOMIZING ARCHIVE \"$@\""; ranlib
++LDCC= $(CC)
++DYNLD= $(CC)
++RANLIB= ranlib
+ ARFLAGS= cr
+ LORDER= lorder
+ TSORT= tsort
+
+ RMDEP= :
+-MKDEP= @echo " ==> MAKING DEPENDENCIES \"$@\""; $(RMDEP); gcc -M
++MKDEP= $(CC) -M
+ MKDEP_OUT=
diff --git a/sysutils/sformat/files/patch-TARGETS::Targetdirs b/sysutils/sformat/files/patch-TARGETS::Targetdirs
new file mode 100644
index 0000000..e13f85e
--- /dev/null
+++ b/sysutils/sformat/files/patch-TARGETS::Targetdirs
@@ -0,0 +1,9 @@
+--- TARGETS/Targetdirs.orig Mon Dec 16 15:33:41 2002
++++ TARGETS/Targetdirs Mon Dec 16 15:34:30 2002
+@@ -1,5 +1,4 @@
+ #ident %W% %E% %Q%
+ ###########################################################################
+-DIRS= patches conf inc lib libdeflt libscg librscg \
+- sformat rscsi man
++DIRS= conf inc lib libscg sformat
+ ###########################################################################
diff --git a/sysutils/sformat/files/patch-sformat::datio.c b/sysutils/sformat/files/patch-sformat::datio.c
new file mode 100644
index 0000000..e776236
--- /dev/null
+++ b/sysutils/sformat/files/patch-sformat::datio.c
@@ -0,0 +1,15 @@
+--- sformat/datio.c.orig Mon Dec 16 16:04:37 2002
++++ sformat/datio.c Mon Dec 16 16:05:11 2002
+@@ -81,11 +81,7 @@
+
+ char *datpath[] = {
+ "",
+- "/opt/schily/etc/",
+- "/usr/bert/etc/",
+- "/etc/",
+- "/usr/etc/",
+- "/opt/schily/etc/",
++ "%%DATADIR%%/",
+ NULL
+ };
+
diff --git a/sysutils/sformat/files/patch-sformat::fmt.c b/sysutils/sformat/files/patch-sformat::fmt.c
new file mode 100644
index 0000000..27cf28e
--- /dev/null
+++ b/sysutils/sformat/files/patch-sformat::fmt.c
@@ -0,0 +1,11 @@
+--- sformat/fmt.c.orig Mon Dec 16 16:26:00 2002
++++ sformat/fmt.c Mon Dec 16 16:27:51 2002
+@@ -482,7 +482,7 @@
+ }
+
+ printf("sformat SCSI format/analysis/repair utilities\n");
+- printf("Release 3.4, Copyright J. Schilling\n\n");
++ printf("Release %s, Copyright J. Schilling\n\n", fmt_version);
+
+ if (!datfile_chk) {
+ if (datfile_present)
diff --git a/sysutils/sformat/files/patch-sformat::sformat.1 b/sysutils/sformat/files/patch-sformat::sformat.1
new file mode 100644
index 0000000..93c7156
--- /dev/null
+++ b/sysutils/sformat/files/patch-sformat::sformat.1
@@ -0,0 +1,11 @@
+--- sformat/sformat.1.orig Mon Dec 16 19:18:21 2002
++++ sformat/sformat.1 Mon Dec 16 19:20:33 2002
+@@ -143,7 +143,7 @@
+ .B sformat
+ looks in the following path:
+ .br
+-.I /opt schily/etc, /etc, /usr/etc.
++.I %%DATADIR%%.
+ .TP
+ .BI debug= "#, " -d
+ Set the misc debug value to # (with debug=#) or increment
diff --git a/sysutils/sformat/pkg-comment b/sysutils/sformat/pkg-comment
new file mode 100644
index 0000000..e6be9db
--- /dev/null
+++ b/sysutils/sformat/pkg-comment
@@ -0,0 +1 @@
+Allows formatting/partitioning/analysis/repairing of SCSI disks
diff --git a/sysutils/sformat/pkg-descr b/sysutils/sformat/pkg-descr
new file mode 100644
index 0000000..3048f2e
--- /dev/null
+++ b/sysutils/sformat/pkg-descr
@@ -0,0 +1,27 @@
+The main advantages to the Sun format utility are:
+- Working surface analyze that will detect defective blocks that are going
+ to get bad.
+- Analyzing program that detects defective bearings in the disk (-randrw).
+- Will repair nearly any defective disk, that has no firmware bug or electric
+ defect.
+- Allows to clear the grown defect list if a disk.
+- Disk geometry and label geometry are separated.
+- Allows cheating in the label geometry to deal with the problems with the
+ limitation to 16 bit data types in the Sun disk label.
+- Large database of disks including firmware specials.
+- You need no desk calculator to generate a partition table.
+ Shorthands for:
+ - MBytes
+ - cylinders/head/sectors
+ - size partition to end on end of disk
+ - partition following another partition
+ - partition ending before another partition
+ - shifting partition on the disk (allows growing part 0 and shrinking part 1)
+- Partition consistency checker with (ascii) graphical display.
+- Mode page interpreter allows to set easily all mode pages you will ever find
+ in a manual, sformat needs not to know about them.
+
+NOTE: Sformat has its full functionality on SunOS/Solaris on sparc
+ and Motorola systems, on all other systems sformat will create
+ Sun disk labels with wrong byte-order, but formatting/analysis/
+ repair will work.
diff --git a/sysutils/sformat/pkg-plist b/sysutils/sformat/pkg-plist
new file mode 100644
index 0000000..ccdc19f
--- /dev/null
+++ b/sysutils/sformat/pkg-plist
@@ -0,0 +1,3 @@
+bin/sformat
+share/sformat/sformat.dat
+@dirrm share/sformat
OpenPOWER on IntegriCloud