libgit2.pc.in


Log

Author Commit Date CI Message
Patrick Steinhardt 22436f29 2017-04-05T14:39:05 pkgconfig: fix handling of prefixes containing whitespaces Our libgit2.pc.in file is quoting the `libdir` variable in our declared "Libs:" line. The intention is to handle whitespaces here, but pkgconfig already does so by automatically escaping whitespace with backslashes. The correct thing to do is to instead quote the prefix, as this is the one which is being substituted by CMake upon installation. As both libdir and includedir will be expanded to "${prefix}/lib" and "${prefix}/include", respectively, pkgconfig will also correctly escape whitespaces. Note that this will actually break when a user manually wants to override libdir and includedir with a path containing whitespace. But actually, this cannot be helped, as always quoting these variables will actuall break the common case of being prefixed with "${prefix}". So we just bail out here and declare this as unsupported out of the box.
Arthur Schreiber 768e185c 2016-01-05T21:55:11 Wrap path in quotes to support paths containing whitespace.
Dominique Leuenberger 5540d9db 2015-09-10T16:11:10 pkg-config: fix directory references in libgit2.pc Before: libdir=/usr//usr/lib64 includedir=/usr//usr/include After: libdir=/usr/lib64 includedir=/usr/include (note the duplication of /usr in the before case)
Vicent Marti 6a5fb1f4 2015-06-29T12:20:01 pkg-config: Sort the different sections Because of the fact that pkg-config is pants-on-head retarded and that the Linux linker *requires* a static library to come before all its dynamic dependencies in the link path, calling `pkg-config --libs --static` was generating the wrong flags for linking. Before this patch: -Wl,-Bsymbolic-functions -Wl,-z,relro -L/usr/local/lib -lcurl -lssh2 -lrt -lgit2 -lssl -lcrypto -ldl -lz After this patch: -Wl,-Bsymbolic-functions -Wl,-z,relro -L/usr/local/lib -lgit2 -lcurl -lssh2 -lrt -lssl -lcrypto -ldl -lz By setting the "Libs" line before all other rules, we make sure that `-lgit2` is the first library in the link path and that it gets its symbols resolved with the libraries coming after it. This fix (ab)uses an implementation detail in `pkg-config` (namely, that flags are output as they are found on the file), but this detail seems to be stable between releases and always gives a stable output.
Carlos Martín Nieto 1ecda61e 2013-10-23T12:58:56 Set the correct dependencies in the pkg-config file When linking statically, the including project needs to know what the current library build depends on so they can link to it. Store this information in the pkg-config file. While here, remove claims that users need to link to zlib or libcrypto.
Veeti Paananen 9795a40f 2012-10-19T17:33:13 Use standard CMake variable names for installation paths Rename INSTALL_INC and INSTALL_BIN to INCLUDE_INSTALL_DIR and BIN_INSTALL_DIR, which are more commonly used. This is also consistent with the variable for the library path which is already LIB_INSTALL_DIR.
Michael Schubert 77ace82d 2012-07-16T12:41:30 libgit2.pc.in: also switch to LIB_INSTALL_DIR b3237ac3 changed CMakeList.txt to use the more standard LIB_INSTALL_DIR variable instead of INSTALL_LIB, but forgot to change libgit2.pc.in etc. accordingly.
Carlos Martín Nieto 2327a7cc 2011-08-07T18:44:08 Create and install pkg-config file This hasn't been working since the switch away from waf. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
Vicent Marti 9d1dcca2 2011-02-07T10:35:58 Add proper version management We now have proper sonames in Mac OS X and Linux, proper versioning on the pkg-config file and proper DLL naming in Windows. The version of the library is defined exclusively in 'src/git2.h'; the build scripts read it from there automatically. Signed-off-by: Vicent Marti <tanoku@gmail.com>
Ingmar Vanhassel 19af3949 2009-01-30T22:55:54 Add support for installing to a libdir other than 'lib'. Signed-off-by: Ingmar Vanhassel <ingmar@exherbo.org> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Steve Frécinaux 6f6a17db 2008-12-31T01:48:36 Fix pkgconfig file wrt last added dependencies libz and libcrypto dependencies were added recently while libgit2.pc did not get updated. Signed-off-by: Steve Frécinaux <code@istique.net> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Steve Frécinaux d7fbfe15 2008-12-30T12:10:01 Add pkg-config support. The libgit2.pc is generated on make install and installed, to allow using the lib through the pkg-config helper. Signed-off-by: Steve Frécinaux <code@istique.net> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>