logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Third-party Modules View previous topic :: View next topic
Reply to topic   Topic: Subversion 1.3 mod_dav_svn for Apache 2.2 Page Previous  1, 2
Author
tdonovan
Moderator


Joined: 17 Dec 2005
Posts: 611
Location: Milford, MA, USA

PostPosted: Tue 05 Sep '06 21:27    Post subject: Reply with quote

I finally got the infamous "MERGE error" - so this now contains a patch to correct this error and some additional notes in the README.txt file about the APR_ICONV_PATH environment variable.

The new SHA1 is ccc8bc164ce015c845ad87bda2e7ce81223d8389

The URL is the same - http://www.tomdonovan.net/download/mod_dav_svn-1.3.2.x-w32.zip



-tom-
Back to top
Jura



Joined: 08 Jun 2006
Posts: 12

PostPosted: Tue 12 Sep '06 16:34    Post subject: Reply with quote

Guys,
I appreciate your efforts, but the new SVN version (1.4) already released. Any plans to build Apache 2.2 modules against it?
Back to top
maniac



Joined: 29 Mar 2006
Posts: 31
Location: Ukraine

PostPosted: Sun 24 Sep '06 8:16    Post subject: Reply with quote

2Jura: I have built it already. When I'll get online next time I will upload it
2tom: Can you tell something more about merge problem and patch that solves it?
Back to top
tdonovan
Moderator


Joined: 17 Dec 2005
Posts: 611
Location: Milford, MA, USA

PostPosted: Sun 24 Sep '06 21:30    Post subject: Reply with quote

maniac,

The "merge" problem is really an APR problem. When the Windows version of apr_stat() is called with just APR_FINFO_PROT; it returns APR_INCOMPLETE, which Subversion treats as failure. If both APR_FINFO_PROT and APR_FINFO_OWNER are passed, apr_stat() works OK.

Below is a patch for Subversion 1.3.2 libsvn_subr\io.c to work around the bug in APR 1.2.7. The lines wrap when you view it, but it should cut & paste OK into an editor. It has 43 lines.

FYI - This is fixed in APR for the next release, per http://svn.apache.org/viewvc?view=rev&revision=425621 - so it won't be a problem with APR 1.2.8+.

-tom-

Code:
--- subversion\libsvn_subr\io.ORIG   2005-11-16 23:05:44.000000000 -0500
+++ subversion\libsvn_subr\io.c   2006-09-06 11:40:56.921875000 -0400
@@ -1021,6 +1021,7 @@
   SVN_ERR (svn_io_open_unique_file (&fd, &tmp_path, path,
                                     ".tmp", TRUE, pool));
   status = apr_stat (&tmp_finfo, tmp_path, APR_FINFO_PROT, pool);
+  if (status == APR_INCOMPLETE) status = apr_stat (&tmp_finfo, tmp_path, (APR_FINFO_PROT | APR_FINFO_OWNER) , pool); // Patch APR bug
   if (status)
     return svn_error_wrap_apr (status, _("Can't get default file perms "
                                          "for file at '%s' (file stat error)"),
@@ -1036,6 +1037,7 @@
     return svn_error_wrap_apr (status, _("Can't open file at '%s'"), path);
 
   status = apr_stat (&finfo, apr_path, APR_FINFO_PROT, pool);
+  if (status == APR_INCOMPLETE) status = apr_stat (&finfo, apr_path, (APR_FINFO_PROT | APR_FINFO_OWNER), pool); // Patch APR bug
   if (status)
     return svn_error_wrap_apr (status, _("Can't get file perms for file at "
                                          "'%s' (file stat error)"), path);
@@ -1064,6 +1066,7 @@
      only on where read perms are granted.  If this fails
      fall through to the svn_io_set_file* calls. */
   status = apr_stat (&finfo, path_apr, APR_FINFO_PROT, pool);
+  if (status == APR_INCOMPLETE) status = apr_stat (&finfo, path_apr, (APR_FINFO_PROT | APR_FINFO_OWNER), pool); //Patch APR bug
   if (status)
     {
       if (ignore_enoent && APR_STATUS_IS_ENOENT (status))
@@ -1163,6 +1166,7 @@
          only on where read perms are granted.  If this fails
          fall through to the apr_file_perms_set() call. */
       status = apr_stat (&finfo, path_apr, APR_FINFO_PROT, pool);
+      if (status == APR_INCOMPLETE) status = apr_stat (&finfo, path_apr, (APR_FINFO_PROT | APR_FINFO_OWNER), pool); //Patch APR bug
       if (status)
         {
           if (ignore_enoent && APR_STATUS_IS_ENOENT (status))
@@ -2386,6 +2390,7 @@
 
 #ifdef WIN32
   status = apr_stat (&finfo, to_path_apr, APR_FINFO_PROT, pool);
+  if (status == APR_INCOMPLETE) status = apr_stat (&finfo, to_path_apr, (APR_FINFO_PROT | APR_FINFO_OWNER), pool);  //Patch APR bug
   if (APR_STATUS_IS_ENOENT (status))
     {
       was_read_only = FALSE;
Back to top
tdonovan
Moderator


Joined: 17 Dec 2005
Posts: 611
Location: Milford, MA, USA

PostPosted: Sun 24 Sep '06 21:44    Post subject: Reply with quote

maniac,

Were you able to get mod_dav_svn 1.4 working for Berkeley DB repositories?
They get (silently) upgraded from v4.3 to v4.4 with Subversion 1.4.

I tried building Berkeley DB 4.4-20 with VC8. I had no problems with this.
I linked my mod_dav_svn with this version (static lib).
Alas, all accesses to a BDB repository via mod_dav_svn give me errors.

I have no probs with FSFS repositories, but I didn't want to make it available until I figure out the BDB thing.

Thanks,
-tom-
Back to top
maniac



Joined: 29 Mar 2006
Posts: 31
Location: Ukraine

PostPosted: Mon 25 Sep '06 12:40    Post subject: Reply with quote

I'll try to catch them on irc and figure out problem =/

Last edited by maniac on Wed 27 Sep '06 21:13; edited 1 time in total
Back to top
jsuchecki



Joined: 27 Sep 2006
Posts: 1
Location: Lausanne, CH

PostPosted: Wed 27 Sep '06 18:18    Post subject: Reply with quote

maniac, tom,

did you guys manage to get 1.4 working? i'd be thankful for binaries;)

thanks,
jakub
Back to top
d7a7z7e7d



Joined: 05 Oct 2006
Posts: 1

PostPosted: Thu 05 Oct '06 1:22    Post subject: Reply with quote

I too would be extremely grateful if you could please upload your compiled 1.4 binaries that work with apache 2.2.

Thanks!
Back to top
gabryael



Joined: 28 Oct 2006
Posts: 1
Location: Ukraine

PostPosted: Sat 28 Oct '06 13:51    Post subject: Reply with quote

I built mod_dav_svn.so for Apache 2.2.3 and SVN 1.4 against APR v1.3.0-dev. Because of problems with access to *old* BDB repositories (BDB repository storage format depend on APR?! I don't know Sad) there is two packages:
without BDB support
and
with BDB support.

First works only with FSFS repositories.
Second package also contains 'new' Subversion command line utilities (also built against latest APR). If you want to use this mod with legacy BDB repositories please refer to Read_Me.txt for more instructions.

If you discover any problems with this mod please send me feedback. (my e-mail in read_me.txt)
Back to top
dc_d00de



Joined: 31 Aug 2006
Posts: 4
Location: Germany

PostPosted: Tue 31 Oct '06 11:23    Post subject: Reply with quote

thanks for your work, i will check it out.
Back to top
paul.miner



Joined: 01 Nov 2006
Posts: 3
Location: Kansas

PostPosted: Wed 01 Nov '06 11:12    Post subject: Reply with quote

gabryael: Your copy seemed to work, except httpd would crash when I tried to lock a file.

I finally bit the bullet and downloaded everything and recompiled it all from sources, using APR 1.2.7, OpenSSL 0.9.8d, Apache 2.2.3, Neon 0.26.2, BDB 4.4.20, and Subversion 1.4.0 (and various other misc). I applied tdonovan's patch to io.c, and used the APR_ICONV1_PATH environment variable in gabryael's readme. I also had to get the latest SDK (2003 R2) to get it to compile (although I found that I only needed to make a few changes to the existing include files, and grab shfolder.lib). After I finally got it compiled, the locking worked. This is my first time using Subversion, so I'm not familiar with the merging thing, but I'll offer the binaries if anyone's interested:

mod_dav_svn.so
intl.dll, intl3_svn.dll, libapr-1.dll, libapriconv-1.dll,libaprutil-1.dll
libdb44.dll
libhttpd.dll

Please let me know if it works/doesn't work for you.
Back to top
paul.miner



Joined: 01 Nov 2006
Posts: 3
Location: Kansas

PostPosted: Sat 04 Nov '06 18:21    Post subject: Reply with quote

gabryael pointed out that my locking problem seemed to be due my copy of httpd.exe and the libapr files he posted using different versions of the VC runtime library (my httpd.exe used msvcrt.dll, his used msvcr80.dll -- VC6 vs VC8). When I first starting working on the compile, my binaries were linked to msvcr80.dll because I was using the include and library files from the 2003 SDK. I wanted it to work with the older libraries, so I modified the VC6 include files to include some of the necessary changes from the 2003 SDK so all the binaries used the VC6 libraries.

I also forgot to post mod_authz_svn.so, so I'll link to it here (and the SSL libs):
mod_authz_svn.so
libeay32.dll, openssl.exe, ssleay32.dll
Back to top
boostpy2005



Joined: 13 Nov 2006
Posts: 2

PostPosted: Mon 13 Nov '06 21:40    Post subject: Reply with quote

paul.miner wrote:
gabryael pointed out that my locking problem seemed to be due my copy of httpd.exe and the libapr files he posted using different versions of the VC runtime library (my httpd.exe used msvcrt.dll, his used msvcr80.dll -- VC6 vs VC8). When I first starting working on the compile, my binaries were linked to msvcr80.dll because I was using the include and library files from the 2003 SDK. I wanted it to work with the older libraries, so I modified the VC6 include files to include some of the necessary changes from the 2003 SDK so all the binaries used the VC6 libraries.

I also forgot to post mod_authz_svn.so, so I'll link to it here (and the SSL libs):
mod_authz_svn.so
libeay32.dll, openssl.exe, ssleay32.dll


Hi paul,

At first I use the binaries of gabryael und then yours. Boths of them seems to work for me, too. But If I do check in one SVN-Repository, which I create with Subversion 1.4 (FSFS format) before i use the new binaries , I bekome the following error message:

szAppName : apache.exe szAppVer : 2.2.3.0 szModName : libapr.dll
szModVer : 0.9.12.0 offset : 00007cfc


Can you tell me if I should at first create new Repositories and then dump & load my Repositories, which are already 1.4!

Or someone else give me some tips?

thanks in advance

HL
Back to top
paul.miner



Joined: 01 Nov 2006
Posts: 3
Location: Kansas

PostPosted: Tue 14 Nov '06 7:35    Post subject: Reply with quote

I notice you said "libapr.dll" instead of "libapr-1.dll". Did you replace all the binaries? My version of the file is 1.2.7.0, and IIRC, gabryael's is 1.3.0.0. Version 0.9.12.0 sounds like an old version. And I'm not sure how important this is, but did you add the environment variable "APR_ICONV1_PATH" (instructions in gabryael's readme file)?
Back to top
boostpy2005



Joined: 13 Nov 2006
Posts: 2

PostPosted: Wed 15 Nov '06 10:35    Post subject: Reply with quote

paul.miner wrote:
I notice you said "libapr.dll" instead of "libapr-1.dll". Did you replace all the binaries? My version of the file is 1.2.7.0, and IIRC, gabryael's is 1.3.0.0. Version 0.9.12.0 sounds like an old version. And I'm not sure how important this is, but did you add the environment variable "APR_ICONV1_PATH" (instructions in gabryael's readme file)?


Hi paul,

thanks. It works for auth, too. I have read the read.me very carefully. It is prima, only I do only know little about how all these work together Embarassed

Maybe my experience can help the other not to disturb you again:
libapr.dll exists under subversion twice and the direcory is in PATH, so
apache does not try to find libapr-1.dll to resolve the necessary funktions!
I rename all of libapr.dll to libapr.dll_. Now works!


Thanks paul and gabryael again!
Back to top


Reply to topic   Topic: Subversion 1.3 mod_dav_svn for Apache 2.2 View previous topic :: View next topic
Post new topic   Forum Index -> Third-party Modules Page Previous  1, 2