Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 16 May 2005 02:02:42 +0400
From:      "Boris B.Samorodov" <bsam@ipt.ru>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/81083: [maintainer update] utilize misc/mime-support vs file mime.types
Message-ID:  <E1DXRC6-0003xq-KA@ns.ipt.ru>
Resent-Message-ID: <200505152210.j4FMA2Br098859@freefall.freebsd.org>

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

>Number:         81083
>Category:       ports
>Synopsis:       [maintainer update] utilize misc/mime-support vs file mime.types
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Sun May 15 22:10:02 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator:     Boris B. Samorodov
>Release:        FreeBSD 5.4-PRERELEASE i386
>Organization:
InPharmTech
>Environment:
System: FreeBSD tfadh.localhost 5.4-PRERELEASE FreeBSD 5.4-PRERELEASE #0: Sun May 1 19:09:27 MSD 2005 bsam@bsam.int.kfs.ru:/usr/obj/usr/src/sys/TFADH i386


>Description:
	Since 2000 (the date of patch-aa) this port is using it's
	own file mime.types. At 2003 we got a misc/mime-support port.
	This patch (thanks to Oliver Lehmann) utilizes using the existing
	port.

	One more tip. The location of mime.types file is written to the
	configuration file (web2ldap/web2ldapcnf/standalone.py) after
	"make patch". The value is taken from a variable $LOCALBASE.

	The patch should be applied to the port (cd /usr/ports/www;
	patch < web2ldap.mime.patch).

	After applying the patch, the file web2ldap/files/patch-aa
	got to have zero lenght and should be removed.
>How-To-Repeat:
	Look at the port's tree.
>Fix:

----- begin -----
diff -ruN web2ldap.orig/Makefile web2ldap/Makefile
--- web2ldap.orig/Makefile	Mon May 16 01:10:55 2005
+++ web2ldap/Makefile	Mon May 16 01:25:58 2005
@@ -7,6 +7,7 @@
 
 PORTNAME=	web2ldap
 PORTVERSION=	0.15.10
+PORTREVISION=	1
 CATEGORIES=	www
 MASTER_SITES=	http://www.web2ldap.de/download/ \
 		http://www.tricknology.org/ports/
@@ -14,10 +15,16 @@
 MAINTAINER=	bsam@ipt.ru
 COMMENT=	Python-based WWW gateway to LDAP servers
 
-RUN_DEPENDS=	${PYTHON_SITELIBDIR}/_ldap.so:${PORTSDIR}/net/py-ldap2
+RUN_DEPENDS=	${PYTHON_SITELIBDIR}/_ldap.so:${PORTSDIR}/net/py-ldap2 \
+		${LOCALBASE}/etc/mime.types:${PORTSDIR}/misc/mime-support
 
 NO_BUILD=	yes
 USE_PYTHON=	yes
+USE_REINPLACE=	yes
+
+post-patch:
+		@${REINPLACE_CMD} -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \
+		${WRKSRC}/etc/web2ldap/web2ldapcnf/standalone.py
 
 SUB_FILES=	pkg-message
 
@@ -26,7 +33,7 @@
 	@${RM} -f ${WRKSRC}/fcgi/web2ldap.py.orig
 	@${RM} -f ${WRKSRC}/scgi/web2ldap.py.orig
 	@${RM} -f ${WRKSRC}/etc/web2ldap/web2ldapcnf/standalone.py.orig
-	@${RM} -f ${WRKSRC}/etc/mime.types.orig
+	@${RM} -f ${WRKSRC}/etc/web2ldap/web2ldapcnf/standalone.py.bak
 	@${RM} -f ${WRKSRC}/sbin/compile.py.orig
 	@${RM} -f ${WRKSRC}/sbin/web2ldap.py.orig
 	@(cd ${WRKSRC} && ${LOCALBASE}/bin/python ./sbin/compile.py)
diff -ruN web2ldap.orig/files/patch-aa web2ldap/files/patch-aa
--- web2ldap.orig/files/patch-aa	Mon May 16 01:10:55 2005
+++ web2ldap/files/patch-aa	Thu Jan  1 03:00:00 1970
@@ -1,86 +0,0 @@
-*** /dev/null	Sat Jul 22 02:21:51 2000
---- etc/mime.types	Sat Jul 22 02:24:24 2000
-***************
-*** 0 ****
---- 1,81 ----
-+ #
-+ # sample mime.types
-+ #
-+ 
-+ application/andrew-inset	ez
-+ application/excel		xls
-+ application/octet-stream	bin
-+ application/oda			oda
-+ application/pdf			pdf
-+ application/pgp			pgp
-+ application/postscript		ps PS eps
-+ application/rtf			rtf
-+ application/x-arj-compressed	arj
-+ application/x-bcpio		bcpio
-+ application/x-chess-pgn		pgn
-+ application/x-cpio		cpio
-+ application/x-csh		csh
-+ application/x-debian-package	deb
-+ application/x-msdos-program	com exe bat
-+ application/x-dvi		dvi
-+ application/x-gtar		gtar
-+ application/x-gunzip		gz
-+ application/x-hdf		hdf
-+ application/x-latex		latex
-+ application/x-mif		mif
-+ application/x-netcdf		cdf nc
-+ application/x-perl		pl pm
-+ application/x-rar-compressed	rar
-+ application/x-sh		sh
-+ application/x-shar		shar
-+ application/x-sv4cpio		sv4cpio
-+ application/x-sv4crc		sv4crc
-+ application/x-tar		tar
-+ application/x-tar-gz		tgz tar.gz
-+ application/x-tcl		tcl
-+ application/x-tex		tex
-+ application/x-texinfo		texi texinfo
-+ application/x-troff		t tr roff
-+ application/x-troff-man		man
-+ application/x-troff-me		me
-+ application/x-troff-ms		ms
-+ application/x-ustar		ustar
-+ application/x-wais-source	src
-+ application/x-zip-compressed	zip
-+ 
-+ audio/basic			snd
-+ audio/midi			mid midi
-+ audio/ulaw			au
-+ audio/x-aiff			aif aifc aiff
-+ audio/x-wav			wav
-+ 
-+ image/gif			gif
-+ image/ief			ief
-+ image/jpeg			jpe jpeg jpg
-+ image/png			png
-+ image/tiff			tif tiff
-+ image/x-cmu-raster		ras
-+ image/x-portable-anymap		pnm
-+ image/x-portable-bitmap		pbm
-+ image/x-portable-graymap	pgm
-+ image/x-portable-pixmap		ppm
-+ image/x-rgb			rgb
-+ image/x-xbitmap			xbm
-+ image/x-xpixmap			xpm
-+ image/x-xwindowdump		xwd
-+ 
-+ text/html			html htm
-+ text/plain			asc txt
-+ text/richtext			rtx
-+ text/tab-separated-values	tsv
-+ text/x-setext			etx
-+ 
-+ video/dl			dl
-+ video/fli			fli
-+ video/gl			gl
-+ video/mpeg			mp2 mpe mpeg mpg
-+ video/quicktime			mov qt
-+ video/x-msvideo			avi
-+ video/x-sgi-movie		movie
-+ 
-+ x-world/x-vrml			vrm vrml wrl
diff -ruN web2ldap.orig/files/patch-ah web2ldap/files/patch-ah
--- web2ldap.orig/files/patch-ah	Mon May 16 01:10:55 2005
+++ web2ldap/files/patch-ah	Mon May 16 01:11:13 2005
@@ -11,5 +11,5 @@
   document_root = os.path.join(web2ldapcnf.web2ldap_dir,'htdocs')
   
   # Path name of mime.types file
-! mime_types = '/usr/local/web2ldap/etc/mime.types'
+! mime_types = '%%LOCALBASE%%/etc/mime.types'
   
diff -ruN web2ldap.orig/pkg-plist web2ldap/pkg-plist
--- web2ldap.orig/pkg-plist	Mon May 16 01:10:55 2005
+++ web2ldap/pkg-plist	Mon May 16 01:11:13 2005
@@ -47,7 +47,6 @@
 web2ldap/etc/httpd/sample-mod_fastcgi.conf
 web2ldap/etc/httpd/sample-mod_scgi.conf
 web2ldap/etc/init.d/web2ldap
-web2ldap/etc/mime.types
 web2ldap/etc/web2ldap/web2ldapcnf/plugins/samba.py
 web2ldap/etc/web2ldap/web2ldapcnf/plugins/msperson.py
 web2ldap/etc/web2ldap/web2ldapcnf/plugins/edirectory.py
------ end ------

WBR
-- 
bsam

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E1DXRC6-0003xq-KA>