Bug 118307 - www/mod_perl2: [PATCH]: fix WITHOUT_APRUTIL_THREADS=yes, minor pkg-list fix, portlint fix
Summary: www/mod_perl2: [PATCH]: fix WITHOUT_APRUTIL_THREADS=yes, minor pkg-list fix, ...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Pav Lucistnik
Depends on:
Reported: 2007-11-28 13:00 UTC by Philip M. Gollucci
Modified: 2008-01-19 19:40 UTC (History)
0 users

See Also:

file.diff (1.91 KB, patch)
2007-11-28 13:00 UTC, Philip M. Gollucci
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Philip M. Gollucci 2007-11-28 13:00:02 UTC
.if ${APACHE_VERSION} >= 21
PLIST_SUB+=    THREADMUTEX="@comment "

is clearly wrong as the threadedness of apr-util/apr does not depend on apache version, but rather the:
  --disable-threads/--enable-threads parameter of ./configure.
In the APR port, you can set WITHOUT_APRUTIL_THREADS=yes to get the disable one.

If you do this, apr-nothr is installed.

Now go build www/mod_perl2 using www/apache22.

This breaks.

This fixes it.  I'm not sure this is the correct FreeBSD port way to get this information in the ports Makefile, but it does work at least for me.

I asked over on dev@apr.apache.org and was told not to use apxs/apr-1-config/apu-1-config by the VP since thats what first came to my mind.

Note, even though devel/apr is 1.2.x you can't discount apr 0.9x since 
www/apache20 bundles 0.9.12 and you can not use the devel/apr port with www/apache20 (thats correct btw).

Fix: Apply patch

Patch attached with submission follows:
Comment 1 Pav Lucistnik freebsd_committer 2007-12-16 12:25:42 UTC
State Changed
From-To: open->feedback

This patch does not cover the scenario where neither apr.h is present. 
Can I suggest something like this instead? 

-.if ${APACHE_VERSION} >= 21 
+.if exists(${LOCALBASE}/include/apr-1/apr.h) 
+APR_H=         ${LOCALBASE}/include/apr-1/apr.h 
+.elif exists(${LOCALBASE}/include/apr/apr.h) 
+APR_H=         ${LOCALBASE}/include/apr/apr.h 
+.if defined(APR_H) 
+APR_HAS_THREADS=       0 
+.if ${APR_HAS_THREADS} == 1 
+MAN3+=         APR::ThreadMutex.3 
PLIST_SUB+=    THREADMUTEX="@comment " 

Comment 2 Pav Lucistnik freebsd_committer 2007-12-16 12:25:42 UTC
Responsible Changed
From-To: freebsd-ports-bugs->pav

Comment 3 philip 2007-12-17 04:08:30 UTC
You certainly can and this is fine to commit.

Philip M. Gollucci (philip@ridecharge.com)
c:323.219.4708 o:703.749.9295x206
Senior System Admin - Riderway, Inc.
http://riderway.com / http://ridecharge.com
1024D/EC88A0BF 0DE5 C55C 6BF3 B235 2DAB  B89E 1324 9B4F EC88 A0BF

Work like you don't need the money,
love like you'll never get hurt,
and dance like nobody's watching.
Comment 4 Pav Lucistnik freebsd_committer 2007-12-17 07:11:16 UTC
State Changed
From-To: feedback->open

Feedback received
Comment 5 Pav Lucistnik freebsd_committer 2007-12-17 07:18:01 UTC
State Changed
From-To: open->feedback

Looks like the APR::ThreadMutex.3 manpage is installed regardless the .pm being 
installed.  Can you verify this?
Comment 6 Pav Lucistnik freebsd_committer 2008-01-02 13:46:25 UTC
Any update on this one?

Pav Lucistnik <pav@oook.cz>

Sun couldn't care less about Linux other than it now being necessary
in order to be buzzword compliant.
  -- Al Dente
Comment 7 Pav Lucistnik freebsd_committer 2008-01-19 19:28:20 UTC
State Changed
From-To: feedback->closed

My version committed
Comment 8 dfilter service freebsd_committer 2008-01-19 19:30:24 UTC
pav         2008-01-19 19:30:20 UTC

  FreeBSD ports repository

  Modified files:
    www/mod_perl2        Makefile pkg-plist 
  - Make the threadedness depend on the actual build of apr-util/apr, instead on
    an Apache version
  PR:             ports/118307 (adapted from)
  Submitted by:   Philip M. Gollucci <pgollucci@p6m7g8.com> (maintainer)
  Revision  Changes    Path
  1.60      +16 -3     ports/www/mod_perl2/Makefile
  1.33      +1 -1      ports/www/mod_perl2/pkg-plist
cvs-all@freebsd.org mailing list
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"