[86196] trunk/dports/www/apache2
ryandesign at macports.org
ryandesign at macports.org
Fri Oct 21 02:17:14 PDT 2011
Revision: 86196
http://trac.macports.org/changeset/86196
Author: ryandesign at macports.org
Date: 2011-10-21 02:17:13 -0700 (Fri, 21 Oct 2011)
Log Message:
-----------
apache2:
* fix build error "unable to infer tagged configuration" (#30566)
* remove `-arch` flags and references to `ccache` from config files including those used by `apxs` which would cause things using `apxs` to possibly build wrong
* re-enable ability to use ccache since this will no longer impact `apxs` (#21001)
* treat `envvars` (#23561) and `index.html` (#22371) like config files: don't register them to the port because the user might modify them
* remove pointless no_startupitem variant which had been added before the existence of launchd
Modified Paths:
--------------
trunk/dports/www/apache2/Portfile
Added Paths:
-----------
trunk/dports/www/apache2/files/libtool-tag.diff
Modified: trunk/dports/www/apache2/Portfile
===================================================================
--- trunk/dports/www/apache2/Portfile 2011-10-21 08:08:30 UTC (rev 86195)
+++ trunk/dports/www/apache2/Portfile 2011-10-21 09:17:13 UTC (rev 86196)
@@ -5,6 +5,7 @@
name apache2
version 2.2.21
+revision 1
categories www
maintainers ryandesign openmaintainer
license Apache-2
@@ -36,7 +37,8 @@
# Both apache and apache2 want to install dbmmanage.1 and other manpages.
conflicts apache
-patchfiles patch-docs-cgi-examples-printenv.diff
+patchfiles patch-docs-cgi-examples-printenv.diff \
+ libtool-tag.diff
post-patch {
reinplace "s|@PREFIX@|${prefix}|g" ${worksrcpath}/docs/cgi-examples/printenv
@@ -81,27 +83,38 @@
--enable-proxy-http \
--enable-proxy-ftp
-configure.ccache no
-
post-configure {
# Setting DYLD_FALLBACK_LIBRARY_PATH instead of DYLD_LIBRARY_PATH
# avoids issues with library collisions (bug #3013)
reinplace "s|DYLD_LIBRARY_PATH|DYLD_FALLBACK_LIBRARY_PATH|g" \
${worksrcpath}/support/envvars-std
+
+ reinplace -E {s| -arch [a-z0-9_]+||g} \
+ ${worksrcpath}/config.nice \
+ ${worksrcpath}/build/config_vars.mk
+ if {[tbool configure.ccache]} {
+ reinplace -E {s|ccache ||g} \
+ ${worksrcpath}/config.nice \
+ ${worksrcpath}/build/config_vars.mk
+ }
}
destroot.violate_mtree yes
post-destroot {
- set confDir ${destroot}${prefix}/apache2/conf
- eval delete ${confDir}/httpd.conf [glob -directory ${confDir}/extra *.conf]
+ set confDir ${destroot}${prefix}/${name}/conf
+ eval delete ${destroot}${prefix}/${name}/bin/envvars \
+ ${confDir}/httpd.conf \
+ [glob -directory ${confDir}/extra *.conf]
- destroot.keepdirs ${destroot}${prefix}/apache2/logs \
+ move ${destroot}${prefix}/${name}/htdocs/index.html ${destroot}${prefix}/${name}/htdocs/index.html.sample
+
+ destroot.keepdirs ${destroot}${prefix}/${name}/logs \
${confDir}/extra
# fix libtool path
- reinplace "s|/apache2/build/libtool|/share/apr-1/build/libtool|g" \
- ${destroot}${prefix}/apache2/build/config_vars.mk
+ reinplace "s|/${name}/build/libtool|/share/apr-1/build/libtool|g" \
+ ${destroot}${prefix}/${name}/build/config_vars.mk
set docdir ${prefix}/share/doc/apache-${version}
xinstall -d ${destroot}${docdir}
@@ -110,16 +123,20 @@
}
post-activate {
- set confDir ${prefix}/apache2/conf
- # Make sure initial conf files are present and set up correctly
+ set confDir ${prefix}/${name}/conf
+ # Copy into place sample or default versions of files user is likely to modify
+ if {![file exists ${prefix}/${name}/htdocs/index.html]} {
+ file copy ${prefix}/${name}/htdocs/index.html.sample ${prefix}/${name}/htdocs/index.html
+ }
+ if {![file exists ${prefix}/${name}/bin/envvars]} {
+ xinstall -m 755 ${prefix}/${name}/bin/envvars-std ${prefix}/${name}/bin/envvars
+ }
if {![file exists ${confDir}/httpd.conf]} {
- file copy ${confDir}/original/httpd.conf \
- ${confDir}/httpd.conf
+ file copy ${confDir}/original/httpd.conf ${confDir}/httpd.conf
}
foreach f [glob -tails -directory ${confDir}/original/extra *.conf] {
if {![file exists ${confDir}/extra/${f}]} {
- file copy ${confDir}/original/extra/${f} \
- ${confDir}/extra/${f}
+ file copy ${confDir}/original/extra/${f} ${confDir}/extra/${f}
}
}
}
@@ -159,17 +176,13 @@
default_variants +preforkmpm
}
-variant no_startupitem description {Do not create a startup item} {
- startupitem.create no
-}
-
startupitem.create yes
startupitem.start \
-"\[ -x ${prefix}/apache2/bin/apachectl \] && ${prefix}/apache2/bin/apachectl start > /dev/null"
+"\[ -x ${prefix}/${name}/bin/apachectl \] && ${prefix}/${name}/bin/apachectl start > /dev/null"
startupitem.stop \
-"\[ -r ${prefix}/apache2/logs/httpd.pid \] && ${prefix}/apache2/bin/apachectl stop > /dev/null"
+"\[ -r ${prefix}/${name}/logs/httpd.pid \] && ${prefix}/${name}/bin/apachectl stop > /dev/null"
startupitem.restart \
-"${prefix}/apache2/bin/apachectl restart > /dev/null"
+"${prefix}/${name}/bin/apachectl restart > /dev/null"
livecheck.type regex
livecheck.url ${homepage}
Added: trunk/dports/www/apache2/files/libtool-tag.diff
===================================================================
--- trunk/dports/www/apache2/files/libtool-tag.diff (rev 0)
+++ trunk/dports/www/apache2/files/libtool-tag.diff 2011-10-21 09:17:13 UTC (rev 86196)
@@ -0,0 +1,68 @@
+https://issues.apache.org/bugzilla/show_bug.cgi?id=47691
+--- build/rules.mk.in.orig 2006-07-12 05:38:44.000000000 +0200
++++ build/rules.mk.in 2009-08-12 18:08:08.000000000 +0200
+@@ -38,17 +38,17 @@
+ COMPILE = $(BASE_CC) @PICFLAGS@
+ CXX_COMPILE = $(BASE_CXX) @PICFLAGS@
+
+-SH_COMPILE = $(LIBTOOL) --mode=compile $(BASE_CC) @SHLTCFLAGS@ -c $< && touch $@
+-SH_CXX_COMPILE = $(LIBTOOL) --mode=compile $(BASE_CXX) @SHLTCFLAGS@ -c $< && touch $@
++SH_COMPILE = $(LIBTOOL) --mode=compile --tag=CC $(BASE_CC) @SHLTCFLAGS@ -c $< && touch $@
++SH_CXX_COMPILE = $(LIBTOOL) --mode=compile --tag=CXX $(BASE_CXX) @SHLTCFLAGS@ -c $< && touch $@
+
+-LT_COMPILE = $(LIBTOOL) --mode=compile $(COMPILE) @LTCFLAGS@ -c $< && touch $@
+-LT_CXX_COMPILE = $(LIBTOOL) --mode=compile $(CXX_COMPILE) @LTCFLAGS@ -c $< && touch $@
++LT_COMPILE = $(LIBTOOL) --mode=compile --tag=CC $(COMPILE) @LTCFLAGS@ -c $< && touch $@
++LT_CXX_COMPILE = $(LIBTOOL) --mode=compile --tag=CXX $(CXX_COMPILE) @LTCFLAGS@ -c $< && touch $@
+
+ # Link-related commands
+
+-LINK = $(LIBTOOL) --mode=link $(CC) $(ALL_CFLAGS) @PILDFLAGS@ $(LT_LDFLAGS) $(ALL_LDFLAGS) -o $@
+-SH_LINK = $(SH_LIBTOOL) --mode=link $(CC) $(ALL_CFLAGS) $(LT_LDFLAGS) $(ALL_LDFLAGS) $(SH_LDFLAGS) $(CORE_IMPLIB) $(SH_LIBS) -o $@
+-MOD_LINK = $(LIBTOOL) --mode=link $(CC) $(ALL_CFLAGS) -static $(LT_LDFLAGS) $(ALL_LDFLAGS) -o $@
++LINK = $(LIBTOOL) --mode=link --tag=CC $(CC) $(ALL_CFLAGS) @PILDFLAGS@ $(LT_LDFLAGS) $(ALL_LDFLAGS) -o $@
++SH_LINK = $(SH_LIBTOOL) --mode=link --tag=CC $(CC) $(ALL_CFLAGS) $(LT_LDFLAGS) $(ALL_LDFLAGS) $(SH_LDFLAGS) $(CORE_IMPLIB) $(SH_LIBS) -o $@
++MOD_LINK = $(LIBTOOL) --mode=link --tag=CC $(CC) $(ALL_CFLAGS) -static $(LT_LDFLAGS) $(ALL_LDFLAGS) -o $@
+
+ # Cross compile commands
+
+@@ -216,7 +216,7 @@
+
+ # Makes an import library from a def file
+ .def.la:
+- $(LIBTOOL) --mode=compile $(MK_IMPLIB) -o $@ $<
++ $(LIBTOOL) --mode=compile --tag=CC $(MK_IMPLIB) -o $@ $<
+
+ #
+ # Dependencies
+--- srclib/apr/configure.orig 2011-09-09 09:29:37.000000000 -0500
++++ srclib/apr/configure 2011-10-20 23:38:32.000000000 -0500
+@@ -24312,7 +24312,7 @@
+
+
+ if test "x$use_libtool" = "xyes"; then
+- lt_compile='$(LIBTOOL) $(LTFLAGS) --mode=compile $(COMPILE) -o $@ -c $< && touch $@'
++ lt_compile='$(LIBTOOL) $(LTFLAGS) --mode=compile --tag=CC $(COMPILE) -o $@ -c $< && touch $@'
+ LT_VERSION="-version-info `$get_version libtool $version_hdr APR`"
+ link="\$(LIBTOOL) \$(LTFLAGS) --mode=link \$(LT_LDFLAGS) \$(COMPILE) \$(LT_VERSION) \$(ALL_LDFLAGS) -o \$@"
+ so_ext='lo'
+--- support/apxs.in.orig 2010-05-10 15:02:56.000000000 -0500
++++ support/apxs.in 2011-10-20 23:37:00.000000000 -0500
+@@ -408,7 +408,7 @@
+ $la =~ s|\.c$|.la|;
+ my $o = $s;
+ $o =~ s|\.c$|.o|;
+- push(@cmds, "$libtool $ltflags --mode=compile $CFG_CC $cflags -I$CFG_INCLUDEDIR $apr_includedir $apu_includedir $opt -c -o $lo $s && touch $slo");
++ push(@cmds, "$libtool $ltflags --mode=compile --tag=CC $CFG_CC $cflags -I$CFG_INCLUDEDIR $apr_includedir $apu_includedir $opt -c -o $lo $s && touch $slo");
+ unshift(@objs, $lo);
+ }
+
+@@ -445,7 +445,7 @@
+ $opt .= " -rpath $CFG_LIBEXECDIR -module -avoid-version $apr_ldflags";
+ }
+
+- push(@cmds, "$libtool $ltflags --mode=link $CFG_CC -o $dso_file $opt $lo");
++ push(@cmds, "$libtool $ltflags --mode=link --tag=CC $CFG_CC -o $dso_file $opt $lo");
+
+ # execute the commands
+ &execute_cmds(@cmds);
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20111021/43b2d462/attachment.html>
More information about the macports-changes
mailing list