Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 13 Jan 2009 03:01:10 +0900
From:      KATO Tsuguru <tkato432@yahoo.com>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/130453: Update port: emulators/mtools to 4.0.1
Message-ID:  <20090113030110.b56be1f0.tkato432@yahoo.com>
Resent-Message-ID: <200901121840.n0CIe2Gi036670@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         130453
>Category:       ports
>Synopsis:       Update port: emulators/mtools to 4.0.1
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Mon Jan 12 18:40:02 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator:     KATO Tsuguru
>Release:        FreeBSD 7.1-RELEASE-p1 i386
>Organization:
>Environment:
>Description:
- Update to version 4.0.1

New file:
files/patch-charsetConv.c
files/pkg-message.in

Remove file:
files/patch-mformat.c
files/patch-sysincludes.h

>How-To-Repeat:
>Fix:

diff -urN /usr/ports/emulators/mtools/Makefile emulators/mtools/Makefile
--- /usr/ports/emulators/mtools/Makefile	2008-11-29 15:27:14.000000000 +0900
+++ emulators/mtools/Makefile	2008-12-09 01:46:29.000000000 +0900
@@ -6,56 +6,64 @@
 #
 
 PORTNAME=	mtools
-PORTVERSION=	3.9.10
-PORTREVISION=	4
+PORTVERSION=	4.0.1
 CATEGORIES=	emulators
-MASTER_SITES=	ftp://ftp.tux.org/pub/knaff/mtools/  \
+MASTER_SITES=	${MASTER_SITE_SUNSITE} \
 		http://mtools.linux.lu/
-
-PATCH_SITES=	http://mtools.linux.lu/
-PATCHFILES=	mtools-3.9.10-20060525.diff.gz
-PATCH_DIST_STRIP=	-p1
+MASTER_SITE_SUBDIR=	utils/disk-management
 
 MAINTAINER=	ports@FreeBSD.org
 COMMENT=	A collection of tools for manipulating MSDOS files
 
-GNU_CONFIGURE=	yes
-.if !defined(WITHOUT_X11)
-USE_XORG=	x11 sm ice xau
-CONFIGURE_ARGS=	--enable-xdf --enable-floppyd
-PLIST_SUB=	WITH_X11=""
-.else
-CONFIGURE_ARGS=	--enable-xdf --disable-floppyd
-PLIST_SUB=	WITH_X11="@comment "
-.endif
-
+USE_BZIP2=	yes
 USE_GMAKE=	yes
+GNU_CONFIGURE=	yes
+CONFIGURE_ENV=	CPPFLAGS="${CPPFLAGS}" LDFLAGS="${LDFLAGS}" \
+		ac_cv_header_malloc_h=no
+CONFIGURE_ARGS=	--enable-xdf
+
+SUB_FILES=	pkg-message
+
+MAN1=		mattrib.1 mbadblocks.1 mcat.1 mcd.1 mclasserase.1 mcopy.1 \
+		mdel.1 mdeltree.1 mdir.1 mdu.1 mformat.1 mkmanifest.1 \
+		minfo.1 mlabel.1 mmd.1 mmount.1 mmove.1 mpartition.1 \
+		mrd.1 mren.1 mshowfat.1 mtoolstest.1 mtools.1 mtype.1 \
+		mzip.1
+MAN5=		mtools.5
 INFO=		mtools
 
-MAN1=		mattrib.1 mbadblocks.1 mcat.1 mcd.1 mclasserase.1 mcopy.1 mdel.1 mdeltree.1 \
-		mdir.1 mdu.1 mformat.1 mkmanifest.1 minfo.1 mlabel.1 mmd.1 mmount.1 \
-		mmove.1 mpartition.1 mrd.1 mren.1 mshowfat.1 \
-		mtoolstest.1 mtools.1 mtype.1 mzip.1
-MAN5=		mtools.5
+.if defined(WITHOUT_ICONV)
+CONFIGURE_ENV+=	ac_cv_header_iconv_h=no
+.else
+USE_ICONV=	yes
+CPPFLAGS+=	-I${LOCALBASE}/include
+LDFLAGS+=	-L${LOCALBASE}/lib -liconv
+.endif
 
-.if !defined(WITHOUT_X11)
+.if defined(WITHOUT_X11)
+CONFIGURE_ARGS+=	--without-x
+PLIST_SUB=	X11="@comment "
+.else
+USE_XORG=	x11 sm ice xau
+PLIST_SUB=	X11=""
 MAN1+=		floppyd.1 floppyd_installtest.1
 .endif
 
 post-patch:
-	@cd ${WRKSRC}; for f in config.c mformat.c mtools.5 mtools.texi; do \
-	 ${MV} -f $$f $$f.orig; \
-	 ${SED} -e s:/etc/mtools.conf:${PREFIX}/etc/mtools.conf: \
-	 < $$f.orig > $$f; done
-	@cd ${WRKSRC}/scripts; for f in ocopy xcopy; do \
-	 if [ ! -f $$f -a -f $$f.orig ]; then ${CP} -p $$f.orig $$f ; fi \
-	 done
+.for file in mformat.c
+	@${REINPLACE_CMD} -e 's|/etc/mtools.conf|${PREFIX}/etc/mtools.conf|g' \
+		${WRKSRC}/${file}
+.endfor
+.for file in mtools.5 mtools.texi
+	@${REINPLACE_CMD} -e 's|/usr/local/etc/|${PREFIX}/etc/|g' \
+		${WRKSRC}/${file}
+.endfor
 
 post-install:
-#	mwrite has been removed by author, but we'll keep it just a bit longer
-	@cd ${PREFIX}/bin && ${LN} -sf mtools mwrite
-	@${LN} -sf ${PREFIX}/man/man1/mcopy.1.gz ${PREFIX}/man/man1/mwrite.1.gz
-	@${INSTALL_DATA} ${WRKSRC}/mtools.conf ${PREFIX}/etc/mtools.conf.sample
-	@${ECHO} "Please verify ${PREFIX}/etc/mtools.conf for your machine."
+	${INSTALL_DATA} ${WRKSRC}/mtools.conf ${PREFIX}/etc/mtools.conf.sample
+.if !exists(${PREFIX}/etc/mtools.conf)
+	@cd ${PREFIX}/etc && ${CP} -f mtools.conf.sample mtools.conf
+.endif
+	@${CAT} ${PKGMESSAGE}
 
 .include <bsd.port.mk>
diff -urN /usr/ports/emulators/mtools/distinfo emulators/mtools/distinfo
--- /usr/ports/emulators/mtools/distinfo	2006-05-30 03:15:18.000000000 +0900
+++ emulators/mtools/distinfo	2008-12-09 00:32:33.000000000 +0900
@@ -1,6 +1,3 @@
-MD5 (mtools-3.9.10-20060525.diff.gz) = e4f40b3c76cb343bdb9aa18b8523fc27
-MD5 (mtools-3.9.10.tar.gz) = 19bc1f06e9c5865b8ad20b1ddd976f5f
-SHA256 (mtools-3.9.10-20060525.diff.gz) = dc03d7212808e3f91c685b09fabd5fb9b21f2e08bb861cf86d33cd82564ef432
-SHA256 (mtools-3.9.10.tar.gz) = 88d3213a5c9613bc9926e7c968df1c3503266d2e9e8aa2c3da5bd18d673613d6
-SIZE (mtools-3.9.10-20060525.diff.gz) = 10040
-SIZE (mtools-3.9.10.tar.gz) = 387208
+MD5 (mtools-4.0.1.tar.bz2) = 4c91d1f26a201e3e7d440e125764790c
+SHA256 (mtools-4.0.1.tar.bz2) = 6ceb7d087b7acb9308f523571eee0ce2788c913c9a2f01a3b03979bb6eb705a9
+SIZE (mtools-4.0.1.tar.bz2) = 272909
diff -urN /usr/ports/emulators/mtools/files/patch-charsetConv.c emulators/mtools/files/patch-charsetConv.c
--- /usr/ports/emulators/mtools/files/patch-charsetConv.c	1970-01-01 09:00:00.000000000 +0900
+++ emulators/mtools/files/patch-charsetConv.c	2008-12-09 00:38:43.000000000 +0900
@@ -0,0 +1,10 @@
+--- charsetConv.c.orig	2008-11-19 06:33:11.000000000 +0900
++++ charsetConv.c	2008-12-09 00:38:26.000000000 +0900
+@@ -5,7 +5,6 @@
+ #include "msdos.h"
+ #include "mtools.h"
+ 
+-#include <iconv.h>
+ #include <stdio.h>
+ #include <errno.h>
+ #include <stdlib.h>
diff -urN /usr/ports/emulators/mtools/files/patch-mformat.c emulators/mtools/files/patch-mformat.c
--- /usr/ports/emulators/mtools/files/patch-mformat.c	2006-05-29 19:02:22.000000000 +0900
+++ emulators/mtools/files/patch-mformat.c	1970-01-01 09:00:00.000000000 +0900
@@ -1,18 +0,0 @@
---- mformat.c~	Sat May 27 07:09:45 2006
-+++ mformat.c	Sat May 27 07:24:05 2006
-@@ -689,6 +689,7 @@
- 	exit(1);
- }
- 
-+#ifdef OS_linux
- static int get_block_geom(int fd, struct MT_STAT *buf, struct device *dev,
- 			  char *errmsg) {
- 	struct hd_geometry geom;
-@@ -733,6 +734,7 @@
- 	size = dev->tracks * dev->heads * dev->sectors + dev->hidden;
- 	return 0;
- }
-+#endif
- 
- void mformat(int argc, char **argv, int dummy)
- {
diff -urN /usr/ports/emulators/mtools/files/patch-sysincludes.h emulators/mtools/files/patch-sysincludes.h
--- /usr/ports/emulators/mtools/files/patch-sysincludes.h	2005-11-17 19:28:21.000000000 +0900
+++ emulators/mtools/files/patch-sysincludes.h	1970-01-01 09:00:00.000000000 +0900
@@ -1,10 +0,0 @@
---- sysincludes.h~	Wed May  1 12:17:51 2002
-+++ sysincludes.h	Wed Nov 16 23:57:42 2005
-@@ -239,7 +239,6 @@
- #endif
- 
- #ifdef HAVE_MALLOC_H
--# include <malloc.h>
- #endif
- 
- #ifdef HAVE_SIGNAL_H
diff -urN /usr/ports/emulators/mtools/files/pkg-message.in emulators/mtools/files/pkg-message.in
--- /usr/ports/emulators/mtools/files/pkg-message.in	1970-01-01 09:00:00.000000000 +0900
+++ emulators/mtools/files/pkg-message.in	2008-12-17 02:24:07.000000000 +0900
@@ -0,0 +1,3 @@
+************************************************************
+Please verify %%PREFIX%%/etc/mtools.conf for your machine.
+************************************************************
diff -urN /usr/ports/emulators/mtools/pkg-plist emulators/mtools/pkg-plist
--- /usr/ports/emulators/mtools/pkg-plist	2005-12-04 18:19:06.000000000 +0900
+++ emulators/mtools/pkg-plist	2008-12-09 01:16:17.000000000 +0900
@@ -1,6 +1,6 @@
-%%WITH_X11%%bin/floppyd
-%%WITH_X11%%bin/floppyd_installtest
 bin/amuFormat.sh
+%%X11%%bin/floppyd
+%%X11%%bin/floppyd_installtest
 bin/mattrib
 bin/mbadblocks
 bin/mcat
@@ -27,11 +27,8 @@
 bin/mtools
 bin/mtoolstest
 bin/mtype
-bin/mwrite
 bin/mxtar
 bin/mzip
 @unexec if cmp -s %D/etc/mtools.conf %D/etc/mtools.conf.sample; then rm -f %D/etc/mtools.conf; fi
 etc/mtools.conf.sample
 @exec if [ ! -f %D/etc/mtools.conf ]; then cp %B/%f %D/etc/mtools.conf; fi
-@exec ln -fs %D/man/man1/mcopy.1.gz %D/man/man1/mwrite.1.gz
-@unexec rm %D/man/man1/mwrite.1.gz
>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090113030110.b56be1f0.tkato432>