Turns out mod_dav_svn.so links to apr and apr-util 0.9 regardless of what apache is linked against, and apache 2.2 requires apr/apr-util 1.0. Patch incoming...
Created attachment 100437 [details, diff] subversion-1.4.0-apache2.2-fix.diff Fixes subversion-1.4.0.ebuild to check apache's minor version, and use apr-config and apu-config if it's 2.0.x, and apr-1-config and apu-1-config otherwise. Without this, apache subprocesses segfault when trying to access a svn repository.
Created attachment 103136 [details, diff] subversion-1.4.2-apache2.2-fix.diff Bug is still present in subversion 1.4.2 ebuild; here's a new patch. This is fairly simple; can this please go in? It's gonna get real old patching this myself every time a new version comes out.
Created attachment 103172 [details, diff] subversion-1.4.2-apache2.2-fix-r1.diff Just realised the previous patch won't work properly if apache2 isn't in USE. This one should work either way.
I'd agree with the patch, except for a small detail: subversion should explicitly depend on the apr slot that it links against. It should not depend on apr-0 if it is going to use apr-1. In fact... if depending on apache, why bother specifying the apr dependency at all? apache will pull it for us. DEPEND="apache2 ( ${APACHE2_DEPEND} ) !apache2 ( dev-util/apr-0* ) ..."
Created attachment 108777 [details, diff] subversion-1.4.2-proper-apr-deps.diff Took the idea from the previous patch but also made the apr dependency conditional on !apache2.
(In reply to comment #4) > I'd agree with the patch, except for a small detail: subversion should > explicitly depend on the apr slot that it links against. It should not depend > on apr-0 if it is going to use apr-1. Ah, good call. I forgot to check DEPEND. Looks like that should work right, though the ebuild will need to be modified if libapr-0 ever disappears from portage. Basing it off my patch in attachment 103172 [details, diff] would just make it select the best version of libapr available. If you wanted to use my latest patch, and add a modified version of your dep change: !apache2? ( dev-libs/apr-util ) ... that would be fine, since subversion can make use of any version of libapr, it just it needs to be selected at compile time. Unless there's a compelling reason to use apr 0.x rather than apr 1.x; I don't really know. Anyway, I'm just nitpicking. Either way should work. ^_^
(In reply to comment #6) > !apache2? ( dev-libs/apr-util ) > > ... that would be fine, since subversion can make use of any version of libapr, > it just it needs to be selected at compile time. Unless there's a compelling > reason to use apr 0.x rather than apr 1.x; I don't really know. I was trying to avoid the following situation: you have apr-0 you emerge subversion and it links properly you emerge apr-1 you eventually nuke apr-0 from your system, because nothing needs it (the dep of subversion is satisfied by apr-1, even though it is linked against apr-0) As to why I picked apr-0 -- because it's the stable one :)
Ah, gotcha. Sounds good to me.
I will try switch a host to apache2.2 + mod_dav_svn tonight. You will hear from me when there are problems. Any chance that an ebuild which builds against apr 1.x when linked against apache 2.2 will be in the portage tree soon?
Georgi's patch (attachment #108777 [details, diff]) fixes segfaults for me, apache-2.2.4 and subversion-1.4.2 (as that is the version the diff is against).
Any particular reason why this hasn't gone in yet? If the patch needs something, please let me know and I'll try to fix it.
The problem is actually that subversion apr autodetection by default chooses the 0.x version instead of the one used by apache2. The correct workaround would be to unmerge apr-0.x (and apu-0.x) for the duration of the merge. Concerning the patch. I've just committed a fixed subversion. It differs from the patches in that it correctly works with 1.1 apr/apr-util when not linked with apache2
you have a typo, it pretty much breaks your patch. --- /usr/portage/dev-util/subversion/subversion-1.4.3.ebuild 2007-03-07 05:05:40.000000000 +0000 +++ subversion-1.4.3.ebuild 2007-03-07 23:06:53.000000000 +0000 @@ -80,7 +80,7 @@ if use apache2; then myconf="--with-apxs=${APXS2}" - apache_minor="(best_version apache | cut -d. -f2)" + apache_minor="$(best_version apache | cut -d. -f2)" if [ ${apache_minor} -gt 0 ]; then apr_suffix="-1" fi
(In reply to comment #13) > you have a typo, it pretty much breaks your patch. > > --- /usr/portage/dev-util/subversion/subversion-1.4.3.ebuild 2007-03-07 > 05:05:40.000000000 +0000 > +++ subversion-1.4.3.ebuild 2007-03-07 23:06:53.000000000 +0000 > @@ -80,7 +80,7 @@ > > if use apache2; then > myconf="--with-apxs=${APXS2}" > - apache_minor="(best_version apache | cut -d. -f2)" > + apache_minor="$(best_version apache | cut -d. -f2)" > if [ ${apache_minor} -gt 0 ]; then > apr_suffix="-1" > fi > This last fix seems to work for me, thanks :-)
Any chance to change the argument to best_version to include the category? This is the only ebuild in the tree that doesn't do it. best_version dev-util/subversion best_version net-www/apache
Has been fixed.
(In reply to comment #16) > Has been fixed. Was the above comment also in respond to comment #15, or only to the discussion up to comment #14? Asking, because best_version is still getting called with "apache" and "subversion" and I was wondering if it is not an unintentional miss.
(In reply to comment #17) > (In reply to comment #16) > > Has been fixed. > Was the above comment also in respond to comment #15, or only to the discussion > up to comment #14? > Asking, because best_version is still getting called with "apache" and > "subversion" and I was wondering if it is not an unintentional miss. Only comment #14. pauldv?
Ooops, seems that the fix is incomplete (in addition to what "best_version" needs): @@ -106,7 +106,7 @@ myconf="${myconf} --with-neon=/usr" fi - append-flags `/usr/bin/apr-config --cppflags` + append-flags `/usr/bin/apr${apr_suffix}-config --cppflags` econf ${myconf} \ $(use_with berkdb berkeley-db) \
The missing cat (and the others) were a miss. Should be fixed now.
(In reply to comment #20) > The missing cat (and the others) were a miss. Should be fixed now. Confirmed. Except for the following triviality in pkg_setup() (nothing major, but still) - ewarn "Presently you have $(best_version subversion)" + ewarn "Presently you have $(best_version dev-util/subversion)"
Yeah, missed it. Fixed in all ebuilds now.