Date: Mon, 23 Sep 2013 12:37:58 +0000 (UTC) From: Andrej Zverev <az@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r327989 - in head/lang: perl5.12 perl5.12/files perl5.14 perl5.14/files perl5.16 perl5.16/files perl5.18 perl5.18/files Message-ID: <201309231237.r8NCbwf1084075@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: az Date: Mon Sep 23 12:37:58 2013 New Revision: 327989 URL: http://svnweb.freebsd.org/changeset/ports/327989 Log: - Now use.perl don't spam /etc/make.conf and using ${LOCALBASE}/etc/perl5_version instead You must switch to DEFAULT_VERSIONS (see ports/UPDATING entry 20130920 by bapt@) if you are still using PERL_VERSION to define a specific version requirement. - bump portrevision Reviewed by: bapt@ Modified: head/lang/perl5.12/Makefile head/lang/perl5.12/files/use.perl head/lang/perl5.14/Makefile head/lang/perl5.14/files/use.perl head/lang/perl5.16/Makefile head/lang/perl5.16/files/use.perl head/lang/perl5.18/Makefile head/lang/perl5.18/files/use.perl Modified: head/lang/perl5.12/Makefile ============================================================================== --- head/lang/perl5.12/Makefile Mon Sep 23 12:34:10 2013 (r327988) +++ head/lang/perl5.12/Makefile Mon Sep 23 12:37:58 2013 (r327989) @@ -3,7 +3,7 @@ PORTNAME= perl PORTVERSION= ${PERL_VERSION} -PORTREVISION= 0 +PORTREVISION= 1 CATEGORIES= lang devel perl5 MASTER_SITES= CPAN \ ${MASTER_SITE_LOCAL:S/$/:local/} \ @@ -172,7 +172,7 @@ post-patch: -e 's|%%PERL_VERSION%%|${PERL_VERSION}|g;' \ -e 's|%%PERL_VER%%|${PERL_VER}|g;' \ -e 's|%%PERL_ARCH%%|${PERL_ARCH}|g;' \ - -e 's|%%MAKE_CONF%%|${__MAKE_CONF}|g;' \ + -e 's|%%PERL5_SIGNATURE%%|${LOCALBASE}/etc/perl5_version|g;' \ -e 's|%%LINK_USRBIN%%|${LINK_USRBIN}|g;' \ ${FILESDIR}/use.perl \ > ${WRKDIR}/use.perl Modified: head/lang/perl5.12/files/use.perl ============================================================================== --- head/lang/perl5.12/files/use.perl Mon Sep 23 12:34:10 2013 (r327988) +++ head/lang/perl5.12/files/use.perl Mon Sep 23 12:37:58 2013 (r327989) @@ -5,7 +5,7 @@ this=`echo -n $0 | /usr/bin/sed -e 's!^.*/!!'` PERL_VERSION="%%PERL_VERSION%%" PERL_VER="%%PERL_VER%%" -MAKE_CONF=%%MAKE_CONF%% +PERL5_SIGNATURE=%%PERL5_SIGNATURE%% banner=`date +"%F %T"` banner="# added by use.perl $banner" if [ -z "${OSVERSION}" ]; then @@ -21,8 +21,8 @@ fi if [ "$2" = "POST-INSTALL" ] ; then need_remove_links=%%LINK_USRBIN%% need_create_links=%%LINK_USRBIN%% - need_cleanup_make_conf=yes - need_spam_make_conf=yes + need_remove_perl5_signature=yes + need_create_perl5_signature=yes need_post_install=yes if [ "${osreldate}" -lt 900022 ]; then need_cleanup_manpath=yes @@ -30,7 +30,7 @@ if [ "$2" = "POST-INSTALL" ] ; then fi elif [ "$2" = "POST-DEINSTALL" ] ; then need_remove_links=%%LINK_USRBIN%% - need_cleanup_make_conf=yes + need_remove_perl5_signature=yes if [ "${osreldate}" -lt 900022 ]; then need_cleanup_manpath=yes fi @@ -96,19 +96,11 @@ do_post_install() cd ${INCLUDEDIR} && ${PKG_PREFIX}/bin/h2ph *.h machine/*.h sys/*.h >/dev/null } -do_cleanup_make_conf() +do_remove_perl5_signature() { - echo -n "Cleaning up ${MAKE_CONF}..." - if [ -f ${MAKE_CONF} ] ; then - /bin/cp -p ${MAKE_CONF} ${MAKE_CONF}.new - /usr/bin/awk 's=0; - /^#.*use.perl/ { s=1; mode=1 } - /^#/ { s=1; if (mode != 1) { mode=0 } } - /.*PERL.*=/ { s=1; if (mode == 1) { mode=2 } } - /^$/ { s=1; if (mode != 2) { mode = 0 } } - { if (s != 1) { mode = 0 } if (mode == 0) print }' ${MAKE_CONF} >${MAKE_CONF}.new - /bin/mv ${MAKE_CONF} ${MAKE_CONF}.bak - /bin/mv ${MAKE_CONF}.new ${MAKE_CONF} + echo -n "Removing ${PERL5_SIGNATURE}..." + if [ -f ${PERL5_SIGNATURE} ] ; then + /bin/rm ${PERL5_SIGNATURE} fi echo " Done." } @@ -130,11 +122,12 @@ do_cleanup_manpath() fi } -do_spam_make_conf() +do_create_perl5_signature() { - echo -n "Spamming ${MAKE_CONF}..." - echo "$banner" >>${MAKE_CONF} - echo "PERL_VERSION=%%PERL_VERSION%%" >>${MAKE_CONF} + echo -n "Creating ${PERL5_SIGNATURE}..." + echo "$banner" >>${PERL5_SIGNATURE} + echo "# Do not modify PERL_VERSION here, instead use DEFAULT_VERSIONS= perl5=${PERL_VER}" >>${PERL5_SIGNATURE} + echo "PERL_VERSION=%%PERL_VERSION%%" >>${PERL5_SIGNATURE} echo " Done." } @@ -152,8 +145,8 @@ do_spam_manpath() [ "$need_remove_links" = "yes" ] && do_remove_links [ "$need_create_links" = "yes" ] && do_create_links [ "$need_post_install" = "yes" ] && do_post_install -[ "$need_cleanup_make_conf" = "yes" ] && do_cleanup_make_conf -[ "$need_spam_make_conf" = "yes" ] && do_spam_make_conf +[ "$need_remove_perl5_signature" = "yes" ] && do_remove_perl5_signature +[ "$need_create_perl5_signature" = "yes" ] && do_create_perl5_signature [ "$need_cleanup_manpath" = "yes" ] && do_cleanup_manpath [ "$need_spam_manpath" = "yes" ] && do_spam_manpath Modified: head/lang/perl5.14/Makefile ============================================================================== --- head/lang/perl5.14/Makefile Mon Sep 23 12:34:10 2013 (r327988) +++ head/lang/perl5.14/Makefile Mon Sep 23 12:37:58 2013 (r327989) @@ -3,7 +3,7 @@ PORTNAME= perl PORTVERSION= ${PERL_VERSION} -PORTREVISION= 0 +PORTREVISION= 1 CATEGORIES= lang devel perl5 MASTER_SITES= CPAN \ ${MASTER_SITE_LOCAL:S/$/:local/} \ @@ -169,7 +169,7 @@ post-patch: -e 's|%%PERL_VERSION%%|${PERL_VERSION}|g;' \ -e 's|%%PERL_VER%%|${PERL_VER}|g;' \ -e 's|%%PERL_ARCH%%|${PERL_ARCH}|g;' \ - -e 's|%%MAKE_CONF%%|${__MAKE_CONF}|g;' \ + -e 's|%%PERL5_SIGNATURE%%|${LOCALBASE}/etc/perl5_version|g;' \ -e 's|%%LINK_USRBIN%%|${LINK_USRBIN}|g;' \ ${FILESDIR}/use.perl \ > ${WRKDIR}/use.perl Modified: head/lang/perl5.14/files/use.perl ============================================================================== --- head/lang/perl5.14/files/use.perl Mon Sep 23 12:34:10 2013 (r327988) +++ head/lang/perl5.14/files/use.perl Mon Sep 23 12:37:58 2013 (r327989) @@ -5,7 +5,7 @@ this=`echo -n $0 | /usr/bin/sed -e 's!^.*/!!'` PERL_VERSION="%%PERL_VERSION%%" PERL_VER="%%PERL_VER%%" -MAKE_CONF=%%MAKE_CONF%% +PERL5_SIGNATURE=%%PERL5_SIGNATURE%% banner=`date +"%F %T"` banner="# added by use.perl $banner" if [ -z "${OSVERSION}" ]; then @@ -21,8 +21,8 @@ fi if [ "$2" = "POST-INSTALL" ] ; then need_remove_links=%%LINK_USRBIN%% need_create_links=%%LINK_USRBIN%% - need_cleanup_make_conf=yes - need_spam_make_conf=yes + need_remove_perl5_signature=yes + need_create_perl5_signature=yes need_post_install=yes if [ "${osreldate}" -lt 900022 ]; then need_cleanup_manpath=yes @@ -30,7 +30,7 @@ if [ "$2" = "POST-INSTALL" ] ; then fi elif [ "$2" = "POST-DEINSTALL" ] ; then need_remove_links=%%LINK_USRBIN%% - need_cleanup_make_conf=yes + need_remove_perl5_signature=yes if [ "${osreldate}" -lt 900022 ]; then need_cleanup_manpath=yes fi @@ -96,19 +96,11 @@ do_post_install() cd ${INCLUDEDIR} && ${PKG_PREFIX}/bin/h2ph *.h machine/*.h sys/*.h >/dev/null } -do_cleanup_make_conf() +do_remove_perl5_signature() { - echo -n "Cleaning up ${MAKE_CONF}..." - if [ -f ${MAKE_CONF} ] ; then - /bin/cp -p ${MAKE_CONF} ${MAKE_CONF}.new - /usr/bin/awk 's=0; - /^#.*use.perl/ { s=1; mode=1 } - /^#/ { s=1; if (mode != 1) { mode=0 } } - /.*PERL.*=/ { s=1; if (mode == 1) { mode=2 } } - /^$/ { s=1; if (mode != 2) { mode = 0 } } - { if (s != 1) { mode = 0 } if (mode == 0) print }' ${MAKE_CONF} >${MAKE_CONF}.new - /bin/mv ${MAKE_CONF} ${MAKE_CONF}.bak - /bin/mv ${MAKE_CONF}.new ${MAKE_CONF} + echo -n "Removing ${PERL5_SIGNATURE}..." + if [ -f ${PERL5_SIGNATURE} ] ; then + /bin/rm ${PERL5_SIGNATURE} fi echo " Done." } @@ -130,11 +122,12 @@ do_cleanup_manpath() fi } -do_spam_make_conf() +do_create_perl5_signature() { - echo -n "Spamming ${MAKE_CONF}..." - echo "$banner" >>${MAKE_CONF} - echo "PERL_VERSION=%%PERL_VERSION%%" >>${MAKE_CONF} + echo -n "Creating ${PERL5_SIGNATURE}..." + echo "$banner" >>${PERL5_SIGNATURE} + echo "# Do not modify PERL_VERSION here, instead use DEFAULT_VERSIONS= perl5=${PERL_VER}" >>${PERL5_SIGNATURE} + echo "PERL_VERSION=%%PERL_VERSION%%" >>${PERL5_SIGNATURE} echo " Done." } @@ -152,8 +145,8 @@ do_spam_manpath() [ "$need_remove_links" = "yes" ] && do_remove_links [ "$need_create_links" = "yes" ] && do_create_links [ "$need_post_install" = "yes" ] && do_post_install -[ "$need_cleanup_make_conf" = "yes" ] && do_cleanup_make_conf -[ "$need_spam_make_conf" = "yes" ] && do_spam_make_conf +[ "$need_remove_perl5_signature" = "yes" ] && do_remove_perl5_signature +[ "$need_create_perl5_signature" = "yes" ] && do_create_perl5_signature [ "$need_cleanup_manpath" = "yes" ] && do_cleanup_manpath [ "$need_spam_manpath" = "yes" ] && do_spam_manpath Modified: head/lang/perl5.16/Makefile ============================================================================== --- head/lang/perl5.16/Makefile Mon Sep 23 12:34:10 2013 (r327988) +++ head/lang/perl5.16/Makefile Mon Sep 23 12:37:58 2013 (r327989) @@ -3,7 +3,7 @@ PORTNAME= perl PORTVERSION= ${PERL_VERSION} -PORTREVISION= 0 +PORTREVISION= 1 CATEGORIES= lang devel perl5 MASTER_SITES= CPAN \ ${MASTER_SITE_LOCAL:S/$/:local/} \ @@ -168,7 +168,7 @@ post-patch: -e 's|%%PERL_VERSION%%|${PERL_VERSION}|g;' \ -e 's|%%PERL_VER%%|${PERL_VER}|g;' \ -e 's|%%PERL_ARCH%%|${PERL_ARCH}|g;' \ - -e 's|%%MAKE_CONF%%|${__MAKE_CONF}|g;' \ + -e 's|%%PERL5_SIGNATURE%%|${LOCALBASE}/etc/perl5_version|g;' \ -e 's|%%LINK_USRBIN%%|${LINK_USRBIN}|g;' \ ${FILESDIR}/use.perl \ > ${WRKDIR}/use.perl Modified: head/lang/perl5.16/files/use.perl ============================================================================== --- head/lang/perl5.16/files/use.perl Mon Sep 23 12:34:10 2013 (r327988) +++ head/lang/perl5.16/files/use.perl Mon Sep 23 12:37:58 2013 (r327989) @@ -5,7 +5,7 @@ this=`echo -n $0 | /usr/bin/sed -e 's!^.*/!!'` PERL_VERSION="%%PERL_VERSION%%" PERL_VER="%%PERL_VER%%" -MAKE_CONF=%%MAKE_CONF%% +PERL5_SIGNATURE=%%PERL5_SIGNATURE%% banner=`date +"%F %T"` banner="# added by use.perl $banner" if [ -z "${OSVERSION}" ]; then @@ -21,8 +21,8 @@ fi if [ "$2" = "POST-INSTALL" ] ; then need_remove_links=%%LINK_USRBIN%% need_create_links=%%LINK_USRBIN%% - need_cleanup_make_conf=yes - need_spam_make_conf=yes + need_remove_perl5_signature=yes + need_create_perl5_signature=yes need_post_install=yes if [ "${osreldate}" -lt 900022 ]; then need_cleanup_manpath=yes @@ -30,7 +30,7 @@ if [ "$2" = "POST-INSTALL" ] ; then fi elif [ "$2" = "POST-DEINSTALL" ] ; then need_remove_links=%%LINK_USRBIN%% - need_cleanup_make_conf=yes + need_remove_perl5_signature=yes if [ "${osreldate}" -lt 900022 ]; then need_cleanup_manpath=yes fi @@ -96,19 +96,11 @@ do_post_install() cd ${INCLUDEDIR} && ${PKG_PREFIX}/bin/h2ph *.h machine/*.h sys/*.h >/dev/null } -do_cleanup_make_conf() +do_remove_perl5_signature() { - echo -n "Cleaning up ${MAKE_CONF}..." - if [ -f ${MAKE_CONF} ] ; then - /bin/cp -p ${MAKE_CONF} ${MAKE_CONF}.new - /usr/bin/awk 's=0; - /^#.*use.perl/ { s=1; mode=1 } - /^#/ { s=1; if (mode != 1) { mode=0 } } - /.*PERL.*=/ { s=1; if (mode == 1) { mode=2 } } - /^$/ { s=1; if (mode != 2) { mode = 0 } } - { if (s != 1) { mode = 0 } if (mode == 0) print }' ${MAKE_CONF} >${MAKE_CONF}.new - /bin/mv ${MAKE_CONF} ${MAKE_CONF}.bak - /bin/mv ${MAKE_CONF}.new ${MAKE_CONF} + echo -n "Removing ${PERL5_SIGNATURE}..." + if [ -f ${PERL5_SIGNATURE} ] ; then + /bin/rm ${PERL5_SIGNATURE} fi echo " Done." } @@ -130,11 +122,12 @@ do_cleanup_manpath() fi } -do_spam_make_conf() +do_create_perl5_signature() { - echo -n "Spamming ${MAKE_CONF}..." - echo "$banner" >>${MAKE_CONF} - echo "PERL_VERSION=%%PERL_VERSION%%" >>${MAKE_CONF} + echo -n "Creating ${PERL5_SIGNATURE}..." + echo "$banner" >>${PERL5_SIGNATURE} + echo "# Do not modify PERL_VERSION here, instead use DEFAULT_VERSIONS= perl5=${PERL_VER}" >>${PERL5_SIGNATURE} + echo "PERL_VERSION=%%PERL_VERSION%%" >>${PERL5_SIGNATURE} echo " Done." } @@ -152,8 +145,8 @@ do_spam_manpath() [ "$need_remove_links" = "yes" ] && do_remove_links [ "$need_create_links" = "yes" ] && do_create_links [ "$need_post_install" = "yes" ] && do_post_install -[ "$need_cleanup_make_conf" = "yes" ] && do_cleanup_make_conf -[ "$need_spam_make_conf" = "yes" ] && do_spam_make_conf +[ "$need_remove_perl5_signature" = "yes" ] && do_remove_perl5_signature +[ "$need_create_perl5_signature" = "yes" ] && do_create_perl5_signature [ "$need_cleanup_manpath" = "yes" ] && do_cleanup_manpath [ "$need_spam_manpath" = "yes" ] && do_spam_manpath Modified: head/lang/perl5.18/Makefile ============================================================================== --- head/lang/perl5.18/Makefile Mon Sep 23 12:34:10 2013 (r327988) +++ head/lang/perl5.18/Makefile Mon Sep 23 12:37:58 2013 (r327989) @@ -3,7 +3,7 @@ PORTNAME= perl PORTVERSION= ${PERL_VERSION} -PORTREVISION= 0 +PORTREVISION= 1 CATEGORIES= lang devel perl5 MASTER_SITES= CPAN \ ${MASTER_SITE_LOCAL:S/$/:local/} \ @@ -149,7 +149,7 @@ post-patch: -e 's|%%PERL_VERSION%%|${PERL_VERSION}|g;' \ -e 's|%%PERL_VER%%|${PERL_VER}|g;' \ -e 's|%%PERL_ARCH%%|${PERL_ARCH}|g;' \ - -e 's|%%MAKE_CONF%%|${__MAKE_CONF}|g;' \ + -e 's|%%PERL5_SIGNATURE%%|${LOCALBASE}/etc/perl5_version|g;' \ -e 's|%%LINK_USRBIN%%|${LINK_USRBIN}|g;' \ ${FILESDIR}/use.perl \ > ${WRKDIR}/use.perl Modified: head/lang/perl5.18/files/use.perl ============================================================================== --- head/lang/perl5.18/files/use.perl Mon Sep 23 12:34:10 2013 (r327988) +++ head/lang/perl5.18/files/use.perl Mon Sep 23 12:37:58 2013 (r327989) @@ -5,7 +5,7 @@ this=`echo -n $0 | /usr/bin/sed -e 's!^.*/!!'` PERL_VERSION="%%PERL_VERSION%%" PERL_VER="%%PERL_VER%%" -MAKE_CONF=%%MAKE_CONF%% +PERL5_SIGNATURE=%%PERL5_SIGNATURE%% banner=`date +"%F %T"` banner="# added by use.perl $banner" if [ -z "${OSVERSION}" ]; then @@ -21,8 +21,8 @@ fi if [ "$2" = "POST-INSTALL" ] ; then need_remove_links=%%LINK_USRBIN%% need_create_links=%%LINK_USRBIN%% - need_cleanup_make_conf=yes - need_spam_make_conf=yes + need_remove_perl5_signature=yes + need_create_perl5_signature=yes need_post_install=yes if [ "${osreldate}" -lt 900022 ]; then need_cleanup_manpath=yes @@ -30,7 +30,7 @@ if [ "$2" = "POST-INSTALL" ] ; then fi elif [ "$2" = "POST-DEINSTALL" ] ; then need_remove_links=%%LINK_USRBIN%% - need_cleanup_make_conf=yes + need_remove_perl5_signature=yes if [ "${osreldate}" -lt 900022 ]; then need_cleanup_manpath=yes fi @@ -96,19 +96,11 @@ do_post_install() cd ${INCLUDEDIR} && ${PKG_PREFIX}/bin/h2ph *.h machine/*.h sys/*.h >/dev/null } -do_cleanup_make_conf() +do_remove_perl5_signature() { - echo -n "Cleaning up ${MAKE_CONF}..." - if [ -f ${MAKE_CONF} ] ; then - /bin/cp -p ${MAKE_CONF} ${MAKE_CONF}.new - /usr/bin/awk 's=0; - /^#.*use.perl/ { s=1; mode=1 } - /^#/ { s=1; if (mode != 1) { mode=0 } } - /.*PERL.*=/ { s=1; if (mode == 1) { mode=2 } } - /^$/ { s=1; if (mode != 2) { mode = 0 } } - { if (s != 1) { mode = 0 } if (mode == 0) print }' ${MAKE_CONF} >${MAKE_CONF}.new - /bin/mv ${MAKE_CONF} ${MAKE_CONF}.bak - /bin/mv ${MAKE_CONF}.new ${MAKE_CONF} + echo -n "Removing ${PERL5_SIGNATURE}..." + if [ -f ${PERL5_SIGNATURE} ] ; then + /bin/rm ${PERL5_SIGNATURE} fi echo " Done." } @@ -130,11 +122,12 @@ do_cleanup_manpath() fi } -do_spam_make_conf() +do_create_perl5_signature() { - echo -n "Spamming ${MAKE_CONF}..." - echo "$banner" >>${MAKE_CONF} - echo "PERL_VERSION=%%PERL_VERSION%%" >>${MAKE_CONF} + echo -n "Creating ${PERL5_SIGNATURE}..." + echo "$banner" >>${PERL5_SIGNATURE} + echo "# Do not modify PERL_VERSION here, instead use DEFAULT_VERSIONS= perl5=${PERL_VER}" >>${PERL5_SIGNATURE} + echo "PERL_VERSION=%%PERL_VERSION%%" >>${PERL5_SIGNATURE} echo " Done." } @@ -152,8 +145,8 @@ do_spam_manpath() [ "$need_remove_links" = "yes" ] && do_remove_links [ "$need_create_links" = "yes" ] && do_create_links [ "$need_post_install" = "yes" ] && do_post_install -[ "$need_cleanup_make_conf" = "yes" ] && do_cleanup_make_conf -[ "$need_spam_make_conf" = "yes" ] && do_spam_make_conf +[ "$need_remove_perl5_signature" = "yes" ] && do_remove_perl5_signature +[ "$need_create_perl5_signature" = "yes" ] && do_create_perl5_signature [ "$need_cleanup_manpath" = "yes" ] && do_cleanup_manpath [ "$need_spam_manpath" = "yes" ] && do_spam_manpath
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201309231237.r8NCbwf1084075>