Date: Fri, 05 Dec 2003 19:03:41 +0900 From: Masafumi NAKANE <max@FreeBSD.org> To: tobez@FreeBSD.org Cc: portmgr@FreeBSD.org Subject: proposal to enable to skip installation of perl mod man pages Message-ID: <8765gvfuo2.wl%max@wide.ad.jp>
next in thread | raw e-mail | index | archive | help
--pgp-sign-Multipart_Fri_Dec__5_19:03:33_2003-1 Content-Type: text/plain; charset=US-ASCII Hi, I've been wanting to install perl and p5-* modules without modules' man pages mainly because: 1. I don't need them since I just use perldoc whenever I need them. 2. Takes much more time to build and install those ports Now, I did a quick hack (patch below) to make it possible to optionally disable installation of man pages of perl modules. As you can see, with this patch: 1. If you build lang/perl5{,.8} with NO_PERL_MAN3 defined, Configure is run with -Dman3dir=' ', resulting in skipping of mod man page installation. 2. For any p5-* port that uses MakeMaker module (PERL_CONFIGURE=yes), MAN3 will be undef'ed if either NO_PERL_MAN3 is defined, or ${PERL5} was build and installed with NO_PERL_MAN3. I tested the patch on 4-STABLE box, by doing portupgrade -fr perl, and it seems to be working ok. Since this patch is supposed to affect no port unless NO_PERL_MAN3 is explicitly specified, I think it's probably safe to be integrated, but I certainly would like to know if there's better ways to achieve this, or if I'm totally overlooking something. Cheers, Max ---------- Index: bsd.port.mk =================================================================== RCS file: /home/ncvs/ports/Mk/bsd.port.mk,v retrieving revision 1.474 diff -u -r1.474 bsd.port.mk --- bsd.port.mk 24 Nov 2003 01:08:41 -0000 1.474 +++ bsd.port.mk 5 Dec 2003 08:41:58 -0000 @@ -1103,6 +1103,12 @@ .else PERL5= ${LOCALBASE}/bin/perl${PERL_VERSION} PERL= ${LOCALBASE}/bin/perl +. if !defined(NO_PERL_MAN3) +_PERL_INSTALLMAN3DIR!= ${PERL5} -MConfig -e 'print "$Config{installman3dir}";' +. if empty(_PERL_INSTALLMAN3DIR) +NO_PERL_MAN3= yes +. endif +. endif .endif .if defined(USE_OPENSSL) @@ -2420,7 +2426,11 @@ CONFIGURE_ARGS+= CC="${CC}" CCFLAGS="${CFLAGS}" PREFIX="${PREFIX}" \ INSTALLPRIVLIB="${PREFIX}/lib" INSTALLARCHLIB="${PREFIX}/lib" CONFIGURE_SCRIPT?= Makefile.PL +. if !defined(NO_PERL_MAN3) MAN3PREFIX?= ${PREFIX}/lib/perl5/${PERL_VERSION} +. else +. undef MAN3 +. endif .undef HAS_CONFIGURE .endif Index: Makefile =================================================================== RCS file: /home/ncvs/ports/lang/perl5.8/Makefile,v retrieving revision 1.66 diff -u -r1.66 Makefile --- Makefile 25 Nov 2003 18:48:26 -0000 1.66 +++ Makefile 5 Dec 2003 08:43:17 -0000 @@ -29,7 +29,6 @@ CONFIGURE_ARGS= -sde -Dprefix=${PREFIX} \ -Darchlib=${PREFIX}/lib/perl5/${PERL_VER}/${PERL_ARCH} \ -Dprivlib=${PREFIX}/lib/perl5/${PERL_VER} \ - -Dman3dir=${PREFIX}/lib/perl5/${PERL_VER}/man/man3 \ -Dman1dir=${PREFIX}/man/man1 \ -Dsitearch=${SITE_PERL}/${PERL_ARCH} \ -Dsitelib=${SITE_PERL} -Dscriptdir=${PREFIX}/bin \ @@ -76,6 +75,12 @@ CONFIGURE_ARGS+= -Dusemymalloc=n .endif +.if !defined(NO_PERL_MAN3) +CONFIGURE_ARGS+= -Dman3dir=${PREFIX}/lib/perl5/${PERL_VER}/man/man3 +.else +CONFIGURE_ARGS+= -Dman3dir=" " +.endif + INCLUDEDIR= /usr/include .include <bsd.port.pre.mk> @@ -112,6 +117,7 @@ perlartistic.1 perlcheat.1 perlgpl.1 perlmacosx.1 perlos400.1 \ perlreref.1 +.if !defined(NO_PERL_MAN3) MAN3= AnyDBM_File.3 Attribute::Handlers.3 AutoLoader.3 AutoSplit.3 \ B.3 B::Asmdata.3 B::Assembler.3 \ B::Bblock.3 B::Bytecode.3 B::C.3 B::CC.3 B::Concise.3 \ @@ -201,6 +207,7 @@ MAN3+= GDBM_File.3 .endif MAN3PREFIX= ${PREFIX}/lib/perl5/${PERL_VER} +.endif LATEST_LINK= perl5.8 Index: Makefile =================================================================== RCS file: /home/ncvs/ports/lang/perl5/Makefile,v retrieving revision 1.58 diff -u -r1.58 Makefile --- Makefile 30 Sep 2003 08:33:56 -0000 1.58 +++ Makefile 5 Dec 2003 08:59:06 -0000 @@ -28,7 +28,6 @@ CONFIGURE_ARGS= -sde -Dprefix=${PREFIX} \ -Darchlib=${PREFIX}/lib/perl5/${PERL_VER}/${PERL_ARCH} \ -Dprivlib=${PREFIX}/lib/perl5/${PERL_VER} \ - -Dman3dir=${PREFIX}/lib/perl5/${PERL_VER}/man/man3 \ -Dsitearch=${PREFIX}/lib/perl5/site_perl/${PERL_VER}/${PERL_ARCH} \ -Dsitelib=${PREFIX}/lib/perl5/site_perl/${PERL_VER} \ -Dscriptdir=${PREFIX}/bin \ @@ -51,6 +50,12 @@ CONFIGURE_ARGS+= -Dusemymalloc=n .endif +.if !defined(NO_PERL_MAN3) +CONFIGURE_ARGS+= -Dman3dir=${PREFIX}/lib/perl5/${PERL_VER}/man/man3 +.else +CONFIGURE_ARGS+= -Dman3dir=" " +.endif + INCLUDEDIR= /usr/include .ifdef USE_PERL5 @@ -87,6 +92,7 @@ pod2usage.1 podchecker.1 podselect.1 pstruct.1 s2p.1 \ splain.1 xsubpp.1 +.if !defined(NO_PERL_MAN3) MAN3= AnyDBM_File.3 AutoLoader.3 AutoSplit.3 B.3 B::Asmdata.3 \ B::Assembler.3 B::Bblock.3 B::Bytecode.3 B::C.3 B::CC.3 \ B::Concise.3 B::Debug.3 B::Deparse.3 B::Disassembler.3 \ @@ -139,6 +145,7 @@ .endif MAN3PREFIX= ${PREFIX}/lib/perl5/${PERL_VER} +.endif test: @(cd ${WRKSRC}; make test) ---------- --pgp-sign-Multipart_Fri_Dec__5_19:03:33_2003-1 Content-Type: application/pgp-signature Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.3 (FreeBSD) iD8DBQA/0Ff9lZYVns41a1kRAgsLAJ9+7JknLtljLQZ/XHVtL2pEFpzKmACgipOu oDuezVJqGbBuV0Sxiqgc4Og= =WzKC -----END PGP SIGNATURE----- --pgp-sign-Multipart_Fri_Dec__5_19:03:33_2003-1--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?8765gvfuo2.wl%max>