You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by "Gretton, Liam" <li...@leicester.ac.uk> on 2021/11/01 08:32:06 UTC

Subversion 1.14.1 build problem

I'm rebuilding our Subversion server, getting it up to date after a fair period of neglect.

I'm finding that 1.41.1 has a problem somewhere in its SQLite code and fails at the make stage. 1.10.7 succeeds with exactly the same build process and dependencies.

I'm using CentOS 7, but with Apache 2.4.8, APR 1.7.0, APR-util 1.6.1 and SQLite 3.36.0.

cd subversion-1.14.1
unzip ../sqlite-amalgamation-3360000.zip
mv sqlite-amalgamation-3360000.zip sqlite-amalgamation

./configure --prefix=/local/software/subversion-1.14.1 \
  --with-lz4=internal \
  --with-utf8proc=internal \
  --with-apxs=/local/software/httpd/bin/apxs \
  --with-apr=/local/software/bin \
  --with-apr-util=/local/software/bin
make

...

In file included from subversion/libsvn_subr/sqlite3wrapper.c:63:0:
/home/liam/downloads/subversion-1.14.1/sqlite-amalgamation/sqlite3.c:38012:12: warning: 'unixFcntlExternalReader' used but never defined [enabled by default]
static int unixFcntlExternalReader(unixFile*, int*);

...

.libs/sqlite3wrapper.o: In function `unixFileControl':
/home/liam/downloads/subversion-1.14.1/sqlite-amalgamation/sqlite3.c:38131: undefined reference to `unixFcntlExternalReader'
/usr/bin/ld: .libs/sqlite3wrapper.o: relocation R_X86_64_PC32 against undefined symbol `unixFcntlExternalReader' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: final link failed: Bad value
collect2: error: ld returned 1 exit status
make: *** [subversion/libsvn_subr/libsvn_subr-1.la] Error 1

Any idea what I can do to get past this?

Thanks,

Liam


RE: Subversion 1.14.1 build problem

Posted by "Gretton, Liam" <li...@leicester.ac.uk>.
Hi Daniel,

Thanks very much for your reply, I've been able to build 1.14.1 with sqlite-amalgamation 3.35.

I'll keep an eye on SQLite releases to see if this gets fixed, I see 3.37.0 is due out in a couple of weeks.

Re: Subversion 1.14.1 build problem

Posted by Nathan Hartman <ha...@gmail.com>.
On Tue, Nov 30, 2021 at 10:33 AM Nathan Hartman
<ha...@gmail.com> wrote:
> I can confirm:
>
> Building 1.14.1:
> - with sqlite-amalgamation 3.36 fails with ld error: undefined
> reference to `unixFcntlExternalReader'.
> - with sqlite-amalgamation 3.37 succeeds.

I've documented it in the 1.14 release notes in case others run into
it in the future:

https://subversion.apache.org/docs/release-notes/1.14.html#issues-other-sqlite-3-36

It also affects 1.13 but that release is EOL.

Cheers,
Nathan

Re: Subversion 1.14.1 build problem

Posted by Nathan Hartman <ha...@gmail.com>.
On Mon, Nov 29, 2021 at 10:19 AM Daniel Sahlberg
<da...@gmail.com> wrote:
>
> Den tis 2 nov. 2021 kl 09:33 skrev Daniel Sahlberg <da...@gmail.com>:
>>
>> Den mån 1 nov. 2021 kl 09:32 skrev Gretton, Liam <li...@leicester.ac.uk>:
(snip)
>> > .libs/sqlite3wrapper.o: In function `unixFileControl':
>> >
>> > /home/liam/downloads/subversion-1.14.1/sqlite-amalgamation/sqlite3.c:38131: undefined reference to `unixFcntlExternalReader'
>> >
>> > /usr/bin/ld: .libs/sqlite3wrapper.o: relocation R_X86_64_PC32 against undefined symbol `unixFcntlExternalReader' can not be used when making a shared object; recompile with -fPIC
(snip)
>> As far as I can tell this is a bug in SQLite. The offending function
>> was added 2021-04-02 [1] and it seems to be hidden by #ifdef
>> SQLITE_OMIT_WAL. There is a reference to the same error in the SQLite
>> forums [2] with a suggestion to leave out SQLITE_OMIT_WAL on
>> compilation.
(snip)
> SQLite 3.37.0 was relased today.
>
> According to a post in the SQLite forums [1], a fix was committed 2021-11-02. When checking the source of 3.37.0 it seems to be included but I'm out of time to verify. Maybe you can try a new build?
>
> Kind regards,
> Daniel
>
>
> [1] https://sqlite.org/forum/forumpost/8066af6dcd79e78490694a324ed655fe6b6588bf5f02db09becb60ea233e5b1a

I can confirm:

Building 1.14.1:
- with sqlite-amalgamation 3.36 fails with ld error: undefined
reference to `unixFcntlExternalReader'.
- with sqlite-amalgamation 3.37 succeeds.

$ ./svn  --version --verbose
svn, version 1.14.1 (r1886195)
   compiled Nov 30 2021, 10:24:06 on x86_64-unknown-linux-gnu

Copyright (C) 2021 The Apache Software Foundation.
This software consists of contributions made by many people;
see the NOTICE file for more information.
Subversion is open source software, see http://subversion.apache.org/

The following repository access (RA) modules are available:

* ra_svn : Module for accessing a repository using the svn network protocol.
  - with Cyrus SASL authentication
  - handles 'svn' scheme
* ra_local : Module for accessing a repository on local disk.
  - handles 'file' scheme
* ra_serf : Module for accessing a repository via WebDAV protocol using serf.
  - using serf 1.3.9 (compiled with 1.3.9)
  - handles 'http' scheme
  - handles 'https' scheme

The following authentication credential caches are available:

* Gnome Keyring
* GPG-Agent

System information:

* running on x86_64-unknown-linux-gnu
  - Debian GNU/Linux 10 (buster) (buster) [Linux 4.19.0-18-rt-amd64]
* linked dependencies:
  - APR 1.6.5 (compiled with 1.6.5)
  - APR-Util 1.6.1 (compiled with 1.6.1)
  - Expat 2.2.6 (compiled with 2.2.6)
  - SQLite 3.37.0 (static)
  - Utf8proc 2.3.0 (compiled with 2.3.0)
  - ZLib 1.2.11 (compiled with 1.2.11)
  - LZ4 1.8.3 (compiled with 1.8.3)
* loaded shared libraries:
  - /lib/x86_64-linux-gnu/libz.so.1.2.11

Cheers,
Nathan

Re: Subversion 1.14.1 build problem

Posted by Daniel Sahlberg <da...@gmail.com>.
Den tis 2 nov. 2021 kl 09:33 skrev Daniel Sahlberg <
daniel.l.sahlberg@gmail.com>:

> Den mån 1 nov. 2021 kl 09:32 skrev Gretton, Liam <
> liam.gretton@leicester.ac.uk>:
> >
> > I'm rebuilding our Subversion server, getting it up to date after a fair
> period of neglect.
> >
> >
> >
> > I'm finding that 1.41.1 has a problem somewhere in its SQLite code and
> fails at the make stage. 1.10.7 succeeds with exactly the same build
> process and dependencies.
> >
> >
> >
> > I'm using CentOS 7, but with Apache 2.4.8, APR 1.7.0, APR-util 1.6.1 and
> SQLite 3.36.0.
> >
> >
> >
> > cd subversion-1.14.1
> >
> > unzip ../sqlite-amalgamation-3360000.zip
> >
> > mv sqlite-amalgamation-3360000.zip sqlite-amalgamation
> >
> >
> >
> > ./configure --prefix=/local/software/subversion-1.14.1 \
> >
> >   --with-lz4=internal \
> >
> >   --with-utf8proc=internal \
> >
> >   --with-apxs=/local/software/httpd/bin/apxs \
> >
> >   --with-apr=/local/software/bin \
> >
> >   --with-apr-util=/local/software/bin
> >
> > make
> >
> >
> >
> > …
> >
> >
> >
> > In file included from subversion/libsvn_subr/sqlite3wrapper.c:63:0:
> >
> >
> /home/liam/downloads/subversion-1.14.1/sqlite-amalgamation/sqlite3.c:38012:12:
> warning: ‘unixFcntlExternalReader’ used but never defined [enabled by
> default]
> >
> > static int unixFcntlExternalReader(unixFile*, int*);
> >
> >
> >
> > …
> >
> >
> >
> > .libs/sqlite3wrapper.o: In function `unixFileControl':
> >
> >
> /home/liam/downloads/subversion-1.14.1/sqlite-amalgamation/sqlite3.c:38131:
> undefined reference to `unixFcntlExternalReader'
> >
> > /usr/bin/ld: .libs/sqlite3wrapper.o: relocation R_X86_64_PC32 against
> undefined symbol `unixFcntlExternalReader' can not be used when making a
> shared object; recompile with -fPIC
> >
> > /usr/bin/ld: final link failed: Bad value
> >
> > collect2: error: ld returned 1 exit status
> >
> > make: *** [subversion/libsvn_subr/libsvn_subr-1.la] Error 1
> >
> >
> >
> > Any idea what I can do to get past this?
>
> Hi!
>
> I reproduce this behaviour.
>
> As far as I can tell this is a bug in SQLite. The offending function
> was added 2021-04-02 [1] and it seems to be hidden by #ifdef
> SQLITE_OMIT_WAL. There is a reference to the same error in the SQLite
> forums [2] with a suggestion to leave out SQLITE_OMIT_WAL on
> compilation.
>
> It seems to be possible to restore the old behaviour by reverting our
> r1865523 (which is defining SQLITE_OMIT_WAL, triggering the build
> failure). I'm adding Evgeny Kotkov, author of r1865523, for a second
> pair of eyes, but I don't think that we are doing anything wrong.
>
> I think it should also be possible to use an older version of SQLite
> (released before 2021-04-02).
>
[1] https://sqlite.org/src/info/e16da5af822ef31d
> [2] https://sqlite.org/forum/info/f4640ddef932093c


SQLite 3.37.0 was relased today.

According to a post in the SQLite forums [1], a fix was committed
2021-11-02. When checking the source of 3.37.0 it seems to be included but
I'm out of time to verify. Maybe you can try a new build?

Kind regards,
Daniel


[1]
https://sqlite.org/forum/forumpost/8066af6dcd79e78490694a324ed655fe6b6588bf5f02db09becb60ea233e5b1a

Re: Subversion 1.14.1 build problem

Posted by Daniel Sahlberg <da...@gmail.com>.
Den mån 1 nov. 2021 kl 09:32 skrev Gretton, Liam <li...@leicester.ac.uk>:
>
> I'm rebuilding our Subversion server, getting it up to date after a fair period of neglect.
>
>
>
> I'm finding that 1.41.1 has a problem somewhere in its SQLite code and fails at the make stage. 1.10.7 succeeds with exactly the same build process and dependencies.
>
>
>
> I'm using CentOS 7, but with Apache 2.4.8, APR 1.7.0, APR-util 1.6.1 and SQLite 3.36.0.
>
>
>
> cd subversion-1.14.1
>
> unzip ../sqlite-amalgamation-3360000.zip
>
> mv sqlite-amalgamation-3360000.zip sqlite-amalgamation
>
>
>
> ./configure --prefix=/local/software/subversion-1.14.1 \
>
>   --with-lz4=internal \
>
>   --with-utf8proc=internal \
>
>   --with-apxs=/local/software/httpd/bin/apxs \
>
>   --with-apr=/local/software/bin \
>
>   --with-apr-util=/local/software/bin
>
> make
>
>
>
> …
>
>
>
> In file included from subversion/libsvn_subr/sqlite3wrapper.c:63:0:
>
> /home/liam/downloads/subversion-1.14.1/sqlite-amalgamation/sqlite3.c:38012:12: warning: ‘unixFcntlExternalReader’ used but never defined [enabled by default]
>
> static int unixFcntlExternalReader(unixFile*, int*);
>
>
>
> …
>
>
>
> .libs/sqlite3wrapper.o: In function `unixFileControl':
>
> /home/liam/downloads/subversion-1.14.1/sqlite-amalgamation/sqlite3.c:38131: undefined reference to `unixFcntlExternalReader'
>
> /usr/bin/ld: .libs/sqlite3wrapper.o: relocation R_X86_64_PC32 against undefined symbol `unixFcntlExternalReader' can not be used when making a shared object; recompile with -fPIC
>
> /usr/bin/ld: final link failed: Bad value
>
> collect2: error: ld returned 1 exit status
>
> make: *** [subversion/libsvn_subr/libsvn_subr-1.la] Error 1
>
>
>
> Any idea what I can do to get past this?

Hi!

I reproduce this behaviour.

As far as I can tell this is a bug in SQLite. The offending function
was added 2021-04-02 [1] and it seems to be hidden by #ifdef
SQLITE_OMIT_WAL. There is a reference to the same error in the SQLite
forums [2] with a suggestion to leave out SQLITE_OMIT_WAL on
compilation.

It seems to be possible to restore the old behaviour by reverting our
r1865523 (which is defining SQLITE_OMIT_WAL, triggering the build
failure). I'm adding Evgeny Kotkov, author of r1865523, for a second
pair of eyes, but I don't think that we are doing anything wrong.

I think it should also be possible to use an older version of SQLite
(released before 2021-04-02).

Kind regards,
Daniel

[1] https://sqlite.org/src/info/e16da5af822ef31d
[2] https://sqlite.org/forum/info/f4640ddef932093c