cmake

Benjamin nystire at gmail.com
Sat Apr 4 22:18:25 PDT 2015


I removed both the static switches, but with or without the libgit2 switch,
I still get the following:
Linking CXX executable TestGpsCoords
/usr/bin/ld: cannot find -lgit2
/usr/bin/ld: cannot find -lgit2
collect2: error: ld returned 1 exit status
CMakeFiles/TestGpsCoords.dir/build.make:230: recipe for target
'TestGpsCoords' failed
make[2]: *** [TestGpsCoords] Error 1
CMakeFiles/Makefile2:61: recipe for target
'CMakeFiles/TestGpsCoords.dir/all' failed
make[1]: *** [CMakeFiles/TestGpsCoords.dir/all] Error 2
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

Libgit2 is installed from the Fedora 21 repositories, but using the qmake
build script hasn't thrown any errors about it in the past. The library was
pulled and (I think) linked statically to the Subsurface binary


On 5 April 2015 at 08:05, Dirk Hohndel <dirk at hohndel.org> wrote:

> On Sun, Apr 05, 2015 at 07:56:27AM +0300, Miika Turkia wrote:
> > On Sun, Apr 5, 2015 at 7:50 AM, Benjamin <nystire at gmail.com> wrote:
> > >
> > > This is the output from your suggested set of switches:
> > > cmake -DCMAKE_BUILD_TYPE=Debug -DLIBDCDEVEL=../libdivecomputer
> > > -DLIBDCSTATIC=1 -DLIBGIT2DEVEL=../libgit2 -DLIBGIT2STATIC=1
> > > -dLIBMARBLEDEVEL=../marble/build ../subsurface
> > >
> > > Linking CXX executable TestGpsCoords
> > > /usr/bin/ld: cannot find -lgit2
> > > /usr/bin/ld: cannot find -lgit2
> > > collect2: error: ld returned 1 exit status
> > > CMakeFiles/TestGpsCoords.dir/build.make:230: recipe for target
> > > 'TestGpsCoords' failed
> > > make[2]: *** [TestGpsCoords] Error 1
> > > CMakeFiles/Makefile2:61: recipe for target
> > > 'CMakeFiles/TestGpsCoords.dir/all' failed
> > > make[1]: *** [CMakeFiles/TestGpsCoords.dir/all] Error 2
> > > Makefile:127: recipe for target 'all' failed
> > > make: *** [all] Error 2
> > >
> > >
> >
> > Try without the libgit specific parameters. (If you have libgit2
> > installed globally.) That Is how I got a working build. Otherwise,
> > make sure you have sources for libgit2 as specified with the
> > parameters.
>
> Yes, these parameters need to match the way you are building.
>
> I also just responded to Benjamin's first email (the one without Cc) that
> I fixed the .qm bug...
>
> Basically if you had done an in-tree build with qmake in your source
> directory then you wouldn't run into this, but if your source directory is
> pristine (only out of tree builds) then the .qm files weren't rebuilt.
> Oops.
>
> Thanks for testing.
>
> And a LOT more testing is needed.
>
> WARNING - WARNING - WARNING
>
> I will deprecate and then remove the qmake support fairly soon!
>
> /D
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.subsurface-divelog.org/pipermail/subsurface/attachments/20150405/892ac422/attachment.html>


More information about the subsurface mailing list