sysutils/sformat: Update to 3.7
Reset maintainer (e-Mail address no longer valid). Switch to schilytools release. AN-2023-04-19: - libschily: no longer provide the symbols fgetline, getline. libschily used to provide these symbols as alternative names for js_getline and js_fgetline for compatibility with UNOS. As their POSIX-incompatible signature causes problems when linking against musl statically, we now no longer provide these symbols by default. Users wishing to restore the old behaviour should remove -DNO_GETLINE_COMPAT from CPPOPTS when compiling libschily. - libschily: accordingly, the man pages getline(3) and fgetline(3) have been renamed to js_getline(3) and js_fgetline(3). - RULES: fix HCC_COM expansion when CCOM=clang. This fixes builds with GNU make when CCOM=clang. Submitted by: Nico Sonack. AN-2021-09-01: - sformat: Added support for gettext() based translations The string "Jörg Schilling" is now separate and in a gettext() call. AN-2021-07-29: - sformat: changed open(..., 0) -> open(..., O_RDONLY) for z/OS Thanks to a report from Matthew R. Wilson - sformat:checkmount.c: did use HAVE_SYS_MNTENT_H instead of HAVE_SYS_MNTTAB_H as a result of a typo that was introduced with the code to #include <sys/mnttab.h>. Thanks to a report from Matthew R. Wilson AN-2018-10-30: - libschily: ovstrcpy() from various programs has been moved to libschily. This affects smake, mkisofs, patch, ved, count, sformat AN-2018-05-25: - sformat: The man page used .cs that dos not work with GNU troff because of a GNU troff bug. We no longer use this command for nroff. Note that the GNU troff bug still applies if you try to print the man page. - sformat: History and Download sections have been added to the man page AN-2018-03-01: - sformat: A new option -randv has been added. This option behaves similar to -randrw but does not write to the disk and thus is less harmful to already impaired disks. - sformat: The random tests now use drand48(). This is needed in order to get a sufficient coverage for modern large disks. AN-2017-09-25: - Sformat: The terminating condition for a manual sector size question for Adaptec controllers has been corrected. AN-2016-01-25: - sformat: A new option scgopts=list has been introduced. AN-2015-11-26: - sformat: diskfmt.c now casts a computation to always result in a long long printf() argument. AN-2015-11-21: - sformat: fixed a printf() format size problem on Minix3 32 bits. Thanks to Heiko Eißfeldt for reporting. AN-2013-05-10 - Include file reordering in sformat to avoid warnings on older platforms AN-2011-08-29: - sformat(1) now compiles and works on Win-DOS using the Microsoft compiler. AN-2011-08-10: - sformat now only sets up signal handlers for existing signals to support MSC AN-2009-12-29: - [...] sformat/datio.c: [...] Do no longer shorten strings using strcpy()/wcscpy() as newer POSIX versions claim that overlapping buffers cause undefined. results and as the Solaris 64 bit libc starting with Build 125,. implements strcpy() using SSE instructions and thus fails with overlapping strings.
This commit is contained in:
parent
8d067f9ca9
commit
dbb9f07917
|
@ -1,46 +1,53 @@
|
|||
# $NetBSD: Makefile,v 1.18 2017/08/19 00:25:19 jlam Exp $
|
||||
#
|
||||
# $NetBSD: Makefile,v 1.19 2023/04/21 14:01:41 micha Exp $
|
||||
|
||||
DISTNAME= sformat-3.5
|
||||
PKGREVISION= 1
|
||||
DISTNAME= 2023-04-19
|
||||
PKGNAME= sformat-3.7
|
||||
CATEGORIES= sysutils
|
||||
MASTER_SITES= ftp://ftp.berlios.de/pub/sformat/
|
||||
MASTER_SITES= https://codeberg.org/schilytools/schilytools/archive/
|
||||
DIST_SUBDIR= schilytools
|
||||
|
||||
MAINTAINER= Andreas.Hallmann@tiscali.de
|
||||
HOMEPAGE= http://freshmeat.net/projects/sformat
|
||||
MAINTAINER= pkgsrc-users@NetBSD.org
|
||||
HOMEPAGE= https://codeberg.org/schilytools/schilytools/
|
||||
COMMENT= SCSI disk maintainance, formating, and ultimative repair tool
|
||||
LICENSE= cddl-1.0
|
||||
|
||||
.include "../../mk/bsd.prefs.mk"
|
||||
|
||||
USE_TOOLS+= gmake
|
||||
TBL?= tbl
|
||||
TOOL_DEPENDS+= smake>=1.7:../../devel/smake
|
||||
SMAKE= MAKEFLAGS= smake
|
||||
MAKE_FLAGS+= DESTDIR=${DESTDIR} INS_BASE=${PREFIX} DEFMANBASE=. MANDIR=${PKGMANDIR}
|
||||
# Honor CPPFLAGS, CFLAGS and LDFLAGS
|
||||
MAKE_FLAGS+= CPPOPTX=${CPPFLAGS:Q} COPTX=${CFLAGS:Q} LDOPTX=${LDFLAGS:Q}
|
||||
|
||||
# avoid picking up a bad ${ARCH} during the build
|
||||
MAKE_ENV+= ARCH=""
|
||||
MAKE_ENV+= MAKEPROG="gmake"
|
||||
MAKE_ENV+= COPTX=${CFLAGS:M*:Q}
|
||||
MAKE_ENV+= LDOPTX=${LDFLAGS:M*:Q}
|
||||
SFORMAT_DB= ${PKG_SYSCONFDIR}/sformat.dat
|
||||
CONF_FILES= ${PREFIX}/share/examples/sformat/sformat.dat ${SFORMAT_DB}
|
||||
SPECIAL_PERMS+= ${PREFIX}/share/examples/sformat/sformat.dat ${REAL_ROOT_USER} ${REAL_ROOT_GROUP} 0644
|
||||
AUTO_MKDIRS= yes
|
||||
|
||||
# Override settings in Makefiles by passing additional settings
|
||||
# on the command-line.
|
||||
#
|
||||
MAKE_FLAGS+= INS_BASE=${DESTDIR}${LOCALBASE:Q}
|
||||
MAKE_FLAGS+= MANDIR=${PKGMANDIR:Q}
|
||||
# Configure config file location
|
||||
SUBST_CLASSES+= fix
|
||||
SUBST_STAGE.fix= pre-configure
|
||||
SUBST_FILES.fix+= sformat/datio.c
|
||||
SUBST_FILES.fix+= sformat/sformat.1
|
||||
SUBST_SED.fix= -e "s,@PKGSRC_SYSCONFDIR@,${PKG_SYSCONFDIR},g"
|
||||
SUBST_MESSAGE.fix= Replace database file path.
|
||||
|
||||
# if we're using a gcc which is named gcc, we need to set CCOM=gcc
|
||||
# in MAKE_ENV so the make infrastructure picks the right options.
|
||||
.if !empty(CC:M*gcc*)
|
||||
MAKE_ENV+= CCOM="gcc"
|
||||
.endif
|
||||
# Shared platform specific code for schilytools (provided by smake package)
|
||||
.include "../../devel/smake/Makefile.common"
|
||||
|
||||
INSTALLATION_DIRS= bin include lib ${PKGMANDIR}/man5 ${PKGMANDIR}/man8
|
||||
do-configure:
|
||||
cd ${WRKSRC}/inc && ${SMAKE} ${MAKE_FLAGS}
|
||||
|
||||
post-extract:
|
||||
${CP} ${WRKSRC}/RULES/os-freebsd.id ${WRKSRC}/RULES/os-dragonfly.id
|
||||
${CP} ${WRKSRC}/RULES/os-freebsd.def ${WRKSRC}/RULES/os-dragonfly.def
|
||||
.for x in amd64 macppc
|
||||
ln -s i386-netbsd-cc.rul ${WRKSRC}/RULES/${x}-netbsd-cc.rul
|
||||
ln -s i386-netbsd-cc.rul ${WRKSRC}/RULES/${x}-netbsd-gcc.rul
|
||||
.endfor
|
||||
do-build:
|
||||
cd ${WRKSRC} && for library in libschily libscg; \
|
||||
do \
|
||||
cd ${WRKSRC}/$${library} && ${SMAKE} ${MAKE_FLAGS}; \
|
||||
done
|
||||
cd ${WRKSRC}/sformat && ${SMAKE} ${MAKE_FLAGS}
|
||||
|
||||
do-install:
|
||||
cd ${WRKSRC}/sformat && ${SMAKE} ${MAKE_FLAGS} install
|
||||
${INSTALL_DATA} ${WRKSRC}/sformat/sformat.dat \
|
||||
${DESTDIR}${PREFIX}/share/examples/sformat/sformat.dat
|
||||
|
||||
.include "../../mk/bsd.pkg.mk"
|
||||
|
|
|
@ -1,13 +1,4 @@
|
|||
@comment $NetBSD: PLIST,v 1.1.1.1 2004/12/02 10:08:03 hubertf Exp $
|
||||
@comment $NetBSD: PLIST,v 1.2 2023/04/21 14:01:41 micha Exp $
|
||||
bin/sformat
|
||||
etc/sformat.dat
|
||||
include/align.h
|
||||
include/avoffset.h
|
||||
lib/libdeflt.a
|
||||
lib/librscg.a
|
||||
lib/libscg.a
|
||||
lib/libschily.a
|
||||
man/man5/makefiles.5
|
||||
man/man5/makerules.5
|
||||
man/man8/sformat.8
|
||||
sbin/rscsi
|
||||
share/examples/sformat/sformat.dat
|
||||
|
|
|
@ -1,14 +1,7 @@
|
|||
$NetBSD: distinfo,v 1.8 2021/10/26 11:20:12 nia Exp $
|
||||
$NetBSD: distinfo,v 1.9 2023/04/21 14:01:41 micha Exp $
|
||||
|
||||
BLAKE2s (sformat-3.5.tar.gz) = 4c61c2bd5aa4e66b7199fe2669e255a35fb96bc66ca53b2b131f932873928c56
|
||||
SHA512 (sformat-3.5.tar.gz) = 6dc90e16d396165625816cb5e7252772ed92e9a06aeac49e10c642886491dd9a7eb3f60b60d584e952d23704a175333a8c8fb2b93fa8d3b447f60d555b048fa3
|
||||
Size (sformat-3.5.tar.gz) = 526375 bytes
|
||||
SHA1 (patch-RULES_rules1_dir) = 25b5f88d65b4d8265417bc97cee63f6346e3b008
|
||||
SHA1 (patch-aa) = e398bc734a7bc48668a0b61d3535c0d87b1a4ccf
|
||||
SHA1 (patch-include_schily_h) = 56eb9cf6f87623bcca5d4d83ab27deeee237bc07
|
||||
SHA1 (patch-lib_stdio_fgetline_c) = 0d9aacf5cebc70522b085d71ef90f9665d8c5d6a
|
||||
SHA1 (patch-libscg_scsitransp_c) = 889ec76b497782ffd42ef13214f0e1ab3187ceaf
|
||||
SHA1 (patch-sformat_defect_c) = 20ba1dfd1f671e216fd04e8dfbf02e6ca605ebf3
|
||||
SHA1 (patch-sformat_diskfmt_c) = bd86beb7d9590c32c75c158c9fb13cff8d60a3e3
|
||||
SHA1 (patch-sformat_io_c) = a0a27221e7151feac100c7fc3eb567f4555a6e1b
|
||||
SHA1 (patch-sformat_makelabel_c) = 84bbf9666fdabbcd65476a2e0389169723252327
|
||||
BLAKE2s (schilytools/2023-04-19.tar.gz) = 61bd4ce5c989eacd5ffffc8e6dd5435ba3594573c310405f2ff78bd52194b1e6
|
||||
SHA512 (schilytools/2023-04-19.tar.gz) = 79e5d59ad84fefd32b689dc60db42cb522bfb2c544e7f5b8c2b85c3597c758519071ec043532d3e9e8b745bf4ff1ad32b4e1103eaac391282435e42a2ef94de5
|
||||
Size (schilytools/2023-04-19.tar.gz) = 5896292 bytes
|
||||
SHA1 (patch-sformat_datio.c) = d1e1a8fa8906f69ae183fcee07a0d2d695c0e015
|
||||
SHA1 (patch-sformat_sformat.1) = bd125a26de0412af23198eb26419ac8333ab6a2f
|
||||
|
|
|
@ -1,15 +0,0 @@
|
|||
$NetBSD: patch-RULES_rules1_dir,v 1.1 2012/06/16 08:55:55 dholland Exp $
|
||||
|
||||
Makefiles should stop on error.
|
||||
|
||||
--- RULES/rules1.dir~ 2000-12-01 16:13:17.000000000 +0000
|
||||
+++ RULES/rules1.dir
|
||||
@@ -32,7 +32,7 @@ $(ALLTARGETS):
|
||||
( \
|
||||
echo " ==> MAKING \"$@\" ON SUBDIRECTORY \"$(CURDIR)/$$DIR\"";\
|
||||
if [ -d ./$$DIR -a -r ./$$DIR/Makefile ] ; then \
|
||||
- cd ./$$DIR;$(MAKE) $(MAKEMACS) XARCH=$(XARCH) DIRNAME=$(CURDIR)/$$DIR $@; \
|
||||
+ cd ./$$DIR;$(MAKE) $(MAKEMACS) XARCH=$(XARCH) DIRNAME=$(CURDIR)/$$DIR $@ || exit 1; \
|
||||
else \
|
||||
echo "NOTICE: Partial source ($(CURDIR)/$$DIR) missing";\
|
||||
fi \
|
|
@ -1,13 +0,0 @@
|
|||
$NetBSD: patch-aa,v 1.1 2007/06/27 13:40:49 joerg Exp $
|
||||
|
||||
--- lib/fconv.c.orig 2007-06-27 13:16:27.000000000 +0000
|
||||
+++ lib/fconv.c
|
||||
@@ -68,7 +68,7 @@ extern char *fcvt __PR((double, int, int
|
||||
#define FOUND_ISXX
|
||||
#endif
|
||||
|
||||
-#if defined(HAVE_IEEEFP_H) && !defined(FOUND_ISXX)
|
||||
+#if defined(HAVE_IEEEFP_H) && !defined(FOUND_ISXX) && !defined(__DragonFly__)
|
||||
/*
|
||||
* SVR4
|
||||
*/
|
|
@ -1,24 +0,0 @@
|
|||
$NetBSD: patch-include_schily_h,v 1.2 2020/05/16 02:15:53 joerg Exp $
|
||||
|
||||
Fix symbol name conflict with POSIX getline().
|
||||
|
||||
--- include/schily.h.orig 2001-02-23 16:28:17.000000000 +0000
|
||||
+++ include/schily.h
|
||||
@@ -90,8 +90,6 @@ extern int fexecle __PR((const char *, F
|
||||
/* 6th arg not const, fexecv forces av[ac] = NULL */
|
||||
extern int fexecv __PR((const char *, FILE *, FILE *, FILE *, int,
|
||||
char **));
|
||||
-extern int fexecve __PR((const char *, FILE *, FILE *, FILE *,
|
||||
- char * const *, char * const *));
|
||||
extern int fgetline __PR((FILE *, char *, int));
|
||||
extern int fgetstr __PR((FILE *, char *, int));
|
||||
extern void file_raise __PR((FILE *, int));
|
||||
@@ -153,7 +151,7 @@ extern char *fillbytes __PR((void *, int
|
||||
extern char *findbytes __PR((const void *, int, char));
|
||||
extern int findline __PR((const char *, char, const char *,
|
||||
int, char **, int));
|
||||
-extern int getline __PR((char *, int));
|
||||
+extern int get_line __PR((char *, int));
|
||||
extern int getstr __PR((char *, int));
|
||||
extern int breakline __PR((char *, char, char **, int));
|
||||
extern int getallargs __PR((int *, char * const**, const char *, ...));
|
|
@ -1,15 +0,0 @@
|
|||
$NetBSD: patch-lib_stdio_fgetline_c,v 1.1 2012/06/16 08:55:55 dholland Exp $
|
||||
|
||||
Fix symbol name conflict with POSIX getline().
|
||||
|
||||
--- lib/stdio/fgetline.c~ 2000-12-03 11:19:29.000000000 +0000
|
||||
+++ lib/stdio/fgetline.c
|
||||
@@ -64,7 +64,7 @@ fgetline(f, buf, len)
|
||||
}
|
||||
|
||||
EXPORT int
|
||||
-getline(buf, len)
|
||||
+get_line(buf, len)
|
||||
char *buf;
|
||||
int len;
|
||||
{
|
|
@ -1,15 +0,0 @@
|
|||
$NetBSD: patch-libscg_scsitransp_c,v 1.1 2012/06/16 08:55:55 dholland Exp $
|
||||
|
||||
Fix symbol name conflict with POSIX getline().
|
||||
|
||||
--- libscg/scsitransp.c Sat Jun 16 04:48:53 2012 -0400
|
||||
+++ libscg/scsitransp.c Sat Jun 16 04:50:37 2012 -0400
|
||||
@@ -302,7 +302,7 @@
|
||||
|
||||
js_printf("%s", msg);
|
||||
flush();
|
||||
- if (getline(okbuf, sizeof(okbuf)) == EOF)
|
||||
+ if (get_line(okbuf, sizeof(okbuf)) == EOF)
|
||||
exit(EX_BAD);
|
||||
if(streql(okbuf, "y") || streql(okbuf, "yes") ||
|
||||
streql(okbuf, "Y") || streql(okbuf, "YES"))
|
|
@ -0,0 +1,20 @@
|
|||
$NetBSD: patch-sformat_datio.c,v 1.1 2023/04/21 14:01:42 micha Exp $
|
||||
|
||||
Search database only in current directory and PKG_SYSCONFDIR
|
||||
|
||||
--- sformat/datio.c.orig 2023-01-12 14:25:40.000000000 +0000
|
||||
+++ sformat/datio.c
|
||||
@@ -79,12 +79,7 @@ EXPORT int datfileerr __PR((char *, ...)
|
||||
|
||||
char *datpath[] = {
|
||||
"",
|
||||
- "/opt/schily/etc/",
|
||||
- "/usr/bert/etc/",
|
||||
- "/etc/",
|
||||
- "/usr/etc/",
|
||||
- "/opt/csw/etc/",
|
||||
- "/opt/schily/etc/",
|
||||
+ "@PKGSRC_SYSCONFDIR@/",
|
||||
NULL
|
||||
};
|
||||
|
|
@ -1,15 +0,0 @@
|
|||
$NetBSD: patch-sformat_defect_c,v 1.1 2012/06/16 08:55:55 dholland Exp $
|
||||
|
||||
Fix symbol name conflict with POSIX getline().
|
||||
|
||||
--- sformat/defect.c Sat Jun 16 04:48:53 2012 -0400
|
||||
+++ sformat/defect.c Sat Jun 16 04:50:37 2012 -0400
|
||||
@@ -238,7 +238,7 @@
|
||||
for (;;) {
|
||||
printf("def> ");
|
||||
flush();
|
||||
- if ((n = getline(line, 80)) == 0)
|
||||
+ if ((n = get_line(line, 80)) == 0)
|
||||
/* return (FALSE);*/
|
||||
continue;
|
||||
if (n == EOF)
|
|
@ -1,15 +0,0 @@
|
|||
$NetBSD: patch-sformat_diskfmt_c,v 1.1 2012/06/16 08:55:55 dholland Exp $
|
||||
|
||||
Fix symbol name conflict with POSIX getline().
|
||||
|
||||
--- sformat/diskfmt.c Sat Jun 16 04:48:53 2012 -0400
|
||||
+++ sformat/diskfmt.c Sat Jun 16 04:50:37 2012 -0400
|
||||
@@ -1014,7 +1014,7 @@
|
||||
}
|
||||
|
||||
printf("Enter filename for database prototype [proto.dat]: ");flush();
|
||||
- (void)getline(name, sizeof(name));
|
||||
+ (void)get_line(name, sizeof(name));
|
||||
if (name[0] == '\0')
|
||||
strcpy(name, "proto.dat");
|
||||
if (streql(name, "-"))
|
|
@ -1,33 +0,0 @@
|
|||
$NetBSD: patch-sformat_io_c,v 1.1 2012/06/16 08:55:55 dholland Exp $
|
||||
|
||||
Fix symbol name conflict with POSIX getline().
|
||||
|
||||
--- sformat/io.c Sat Jun 16 04:48:53 2012 -0400
|
||||
+++ sformat/io.c Sat Jun 16 04:50:37 2012 -0400
|
||||
@@ -245,7 +245,7 @@
|
||||
(*prt)(s, *lp, mini, maxi, dp);
|
||||
flush();
|
||||
line[0] = '\0';
|
||||
- if (getline(line, 80) == EOF)
|
||||
+ if (get_line(line, 80) == EOF)
|
||||
exit(EX_BAD);
|
||||
|
||||
linep = skipwhite(line);
|
||||
@@ -332,7 +332,7 @@
|
||||
printf("%r", form, args);
|
||||
va_end(args);
|
||||
flush();
|
||||
- if (getline(okbuf, sizeof(okbuf)) == EOF)
|
||||
+ if (get_line(okbuf, sizeof(okbuf)) == EOF)
|
||||
exit(EX_BAD);
|
||||
if (okbuf[0] == '?') {
|
||||
printf("Enter 'y', 'Y', 'yes' or 'YES' if you agree with the previous asked question.\n");
|
||||
@@ -412,7 +412,7 @@
|
||||
printf("%s [%s]:", s, csp->s_name);
|
||||
flush();
|
||||
line[0] = '\0';
|
||||
- if (getline(line, 80) == EOF)
|
||||
+ if (get_line(line, 80) == EOF)
|
||||
exit(EX_BAD);
|
||||
|
||||
linep = skipwhite(line);
|
|
@ -1,24 +0,0 @@
|
|||
$NetBSD: patch-sformat_makelabel_c,v 1.1 2012/06/16 08:55:55 dholland Exp $
|
||||
|
||||
Fix symbol name conflict with POSIX getline().
|
||||
|
||||
--- sformat/makelabel.c Sat Jun 16 04:48:53 2012 -0400
|
||||
+++ sformat/makelabel.c Sat Jun 16 04:50:37 2012 -0400
|
||||
@@ -284,7 +284,7 @@
|
||||
if (yes("Label: <%s> change ? ", labelbuf)) {
|
||||
printf("Enter disk label: "); flush();
|
||||
tty_insert(labelbuf);
|
||||
- (void)getline(lbuf, sizeof(lbuf));
|
||||
+ (void)get_line(lbuf, sizeof(lbuf));
|
||||
strcpy(labelbuf, lbuf);
|
||||
|
||||
}
|
||||
@@ -296,7 +296,7 @@
|
||||
if (yes("Volume Name: <%s> change ? ", lbuf)) {
|
||||
printf("Enter volume name: "); flush();
|
||||
tty_insert(lbuf);
|
||||
- (void)getline(lbuf, LEN_DKL_VVOL+1);
|
||||
+ (void)get_line(lbuf, LEN_DKL_VVOL+1);
|
||||
strncpy(lp->dkl_vtoc.v_volume, lbuf, LEN_DKL_VVOL);
|
||||
}
|
||||
#endif
|
|
@ -0,0 +1,24 @@
|
|||
$NetBSD: patch-sformat_sformat.1,v 1.1 2023/04/21 14:01:42 micha Exp $
|
||||
|
||||
Search database only in current directory and PKG_SYSCONFDIR
|
||||
|
||||
--- sformat/sformat.1.orig 2023-01-30 14:39:40.055988371 +0000
|
||||
+++ sformat/sformat.1
|
||||
@@ -157,7 +157,7 @@ If no file of the appropriate name was f
|
||||
.B sformat
|
||||
looks in the following path:
|
||||
.br
|
||||
-.I /opt schily/etc, /etc, /usr/etc.
|
||||
+.I @PKGSRC_SYSCONFDIR@.
|
||||
.br
|
||||
.ne 3
|
||||
.TP
|
||||
@@ -1370,7 +1370,7 @@ the end of this partition and the end of
|
||||
.SH FILES
|
||||
.PP
|
||||
.TP 20
|
||||
-.B /opt/schily/etc/sformat.dat
|
||||
+.B @PKGSRC_SYSCONFDIR@/sformat.dat
|
||||
A database with mode pages and disk partitions for disks.
|
||||
.\" .SH "SEE ALSO"
|
||||
.\" .SH DIAGNOSTICS
|
Loading…
Reference in New Issue