CMakeLists.txt


Log

Author Commit Date CI Message
Yong Li 57aa839c 2015-05-04T09:41:34 Android build doesn't need deps/regex deps/regex was included in Android build because Android NDK 4 has a packaging bug and doesn't have the regular expression functions defined in its libc.so. The bug has been fixed in subsequent Android NDK releases. If it is still necessary to work around the bug in Android NDK 4, we should consider to use an option like ANDROID_NDK_RELEASE or ANDROID_NDK_RELEASE_NUM.
Carlos Martín Nieto 24e53d2f 2015-03-19T09:55:20 Rename GIT_SSL to GIT_OPENSSL This is what it's meant all along, but now we actually have multiple implementations, it's clearer to use the name of the library.
Carlos Martín Nieto 6bb54cbf 2014-11-02T13:23:32 Add a SecureTransport TLS channel As an alternative to OpenSSL when we're on OS X. This one can actually take advantage of stacking the streams.
Jeff Hostetler d06c589f 2015-04-10T06:15:06 Add MSVC CRTDBG memory leak reporting.
Tony Kelman b631e0d9 2015-03-19T07:25:25 Use swprintf_s everywhere except mingw.org
Tony Kelman 547517d7 2015-03-16T14:49:23 use a different .def file for 64 bit
Tony Kelman d612e48e 2015-03-16T13:30:10 Fix out-of-tree build link against crypt32 for CertFreeCertificateContext
Philip Kelley 8f426d7d 2014-06-09T11:43:25 Win32: Enable WinHTTP for MinGW
Tony Kelman 06353282 2015-03-05T15:48:08 Only run -ionline tests IF (WINHTTP OR OPENSSL_FOUND)
Jeff Hostetler 9a859ef5 2015-03-02T09:21:55 Added cl_perf_timer. Updated global trace to include timers.
Jeff Hostetler 6b5c0886 2015-02-13T16:58:14 Provide mechanism to let CLAR globally setup git_trace()
Leo Yang 2d2aa1ff 2015-02-13T17:28:35 Fix Mac build without OpenSSL If OpenSSL is disabled on Mac the SHA1 implementation goes to the CommonCrypto from the system. In this case we should not include the generic hash impl. Otherwise there would be duplicated impls which fail the build.
Carlos Martín Nieto 5a2a5771 2015-02-12T00:34:48 Merge pull request #2845 from rakuco/libssh2-detection-fix Add libssh2's library and include directories.
Yury G. Kudryashov e15a0849 2015-02-04T00:15:11 Tell user if libssh was not found Fixes #2665
Raphael Kubo da Costa 461fd5a0 2015-01-24T16:15:12 Add libssh2's library and include directories. Follow-up to 4f91bfa ("Find libssh2 via pkg-config"): FindPkgConfig sets <foo>_INCLUDE_DIRS, not <foo>_INCLUDE_DIR like FindLIBSSH2 did. Additionally, if using only FindPkgConfig to find libssh2, we have to call LINK_DIRECTORIES() as well to pass the appropriate -L entries, otherwise the build will only work if libssh2.so is in a directory searched automatically by the linker.
Leo Yang 7641327c 2015-01-13T16:53:07 Add option to turn off OpenSSL
Edward Thomson 6e1205ef 2014-12-22T12:40:04 cmake: include FindPkgConfig for windows Apparently FindPkgConfig is not included by default on VS builds, only Unix and Unix-like (mingw) builds.
Carlos Martín Nieto 4f91bfa3 2014-12-05T10:32:59 Find libssh2 via pkg-config We don't really need our own module to find libssh2. Using pkg-config lets the standard tool do the work for us and let us fit more naturally in the workflow as we respect the pkg-config search paths.
Carlos Martín Nieto 79b0ae4e 2014-10-27T10:30:57 Flip THREADSAFE's default to ON Threads are here to stay; and for a while now, users have had to call the initialization function which sets up threads and crypto regardless of whether the library was built threadsafe or not.
Edward Thomson a747ea49 2014-10-24T14:01:13 Merge pull request #2647 from ethomson/clar_tmpname clar: use a custom temp directory name
Edward Thomson 29eed1c7 2014-10-24T10:50:57 clar: use a custom temp directory name
Carlos Martín Nieto d9c0dbb0 2014-10-24T13:29:11 hash: use CommonCrypto on OSX for SHA-1 OSX has its own cryptographic library, let's make use of it instead of calling out to OpenSSL.
Carlos Martín Nieto 3753110a 2014-06-17T15:37:21 Provide option to embed libssh2
Edward Thomson 23135afa 2014-08-14T11:52:20 Introduce proper http authentication API
Edward Thomson 315cb38e 2014-07-31T18:43:20 Add GSSAPI support for SPNEGO/Kerberos auth over HTTP
Carlos Martín Nieto 00b8c216 2014-06-30T23:18:37 ssh: always declare the libssh2 types This lets a user decide they do want to use keyboard-interactive after they've compiled.
Carlos Martín Nieto eac63e67 2014-06-30T10:03:36 ssh: create the right callback signature based on build options When linking against libssh2, create the transport.h such that it contains its definition for custom crypto and keyboard-interactive callbacks. If we don't link against libssh2, create an equivalent signature which has void pointers instead of pointers to libssh2 structures. This would be one way to fix #2438.
Carlos Martín Nieto 99807672 2014-06-08T19:42:54 Change SOVERSION at API breaks Since the SOVERSION doesn't need to follow the library's version and simply needs to be monotonically increasing whenever we release something that breaks the ABI, we can set some number and allow multiple versions of the library to be installed side-by-side. We start here with the minor version as that's what we release for now, and it allows to backport this change to earlier versions.
Jeff King 6bcb0987 2014-05-08T00:35:56 cmake: s/ICONV/Iconv/ in FIND_PACKAGE The cmake module we provide is in the file FindIconv.cmake, so we must match the case correctly. It happens to work in practice because we only turn on ICONV on Darwin, and people generally have case-insensitive filesystems there. Note that we only need to update the package name here. The package itself still sets the all-uppercase ICONV_FOUND flag, so we continue to use uppercase in the rest of cmake.
Russell Belfer cd424ad5 2014-04-28T16:39:53 Add GIT_STATUS_OPT_UPDATE_INDEX and use trace API This adds an option to refresh the stat cache while generating status. It also rips out the GIT_PERF stuff I had an makes use of the trace API to keep statistics about what happens during diff.
Russell Belfer 240f4af3 2014-04-28T14:04:29 Add build option for diff internal statistics
Vicent Marti 9d878fc4 2014-05-01T01:23:10 Merge pull request #2304 from jacquesg/solaris Solaris!
Jacques Germishuys 98b8fcff 2014-04-29T20:45:02 Build regex.c for Solaris. Added required defines for Solaris
Carlos Martín Nieto f5fc63bc 2014-04-30T10:55:58 Don't exclude libssh2 from MinGW It reportedly works. It does not however work when cross-compiling on Travis, so let's disable it there. This fixes #2311.
Ting-Wei Lan 096ac799 2014-02-13T22:38:23 Workaround missing .pc files on FreeBSD This fixes #2118
Carlos Martín Nieto 04739e9f 2014-04-30T10:15:44 Unquiet CMake output The point of this phase is to know what we have and not. Show the user a clear indication of what we have.
Marcin Sawicki 7f0de93a 2014-04-28T15:24:36 Make the build CMake 2.6 compatible
Jacques Germishuys 5c8d5eac 2014-04-19T23:07:50 Introduce AddCFlagIfSupported CMake macro
Jacques Germishuys 364ef528 2014-04-18T19:13:18 Only disable deprecation warnings on Apple for OpenSSL
Jacques Germishuys c6cd3f8b 2014-04-18T18:32:06 Use CHECK_C_COMPILER_FLAG to determine if the compiler supports a flag This simplifies platform/compiler dependent checks where we optionally enable features or disable warnings.
Jacques Germishuys 48ce93e0 2014-04-18T18:58:57 Fix inconsistent use of lower-case and upper-case names for macros
Russell Belfer 823c0e9c 2014-04-17T11:53:13 Fix broken logic for attr cache invalidation The checks to see if files were out of date in the attibute cache was wrong because the cache-breaker data wasn't getting stored correctly. Additionally, when the cache-breaker triggered, the old file data was being leaked.
Linquize 9e1ed9f2 2014-04-01T23:01:40 Add CFLAGS -Wdeclaration-after-statement This warns local variables declarations after statement, which helps not to break MSVC
Anurag Gupta 169fb81d 2014-03-11T11:56:26 Undoing local change done for building on x64
Anurag Gupta 7ca1584b 2014-03-11T11:49:19 Conforming to libgit2 coding style.
Miha 6874cafd 2014-03-03T12:08:17 cmake examples change so that general.c is off by default
Miha 058956ce 2014-03-03T11:47:06 - CMakeLists.txt small fix
Miha 300f4412 2014-02-25T11:56:11 - BUGFIX #2133 (@fourplusone) in smart_protocol.c - added MSVC cmake definitions to disable warnings - general.c is rewritten so it is ansi-c compatible and compiles ok on microsoft windows - some MSVC reported warning fixes
Tobias Marquardt 5bda607c 2014-02-21T01:09:44 Check if librt exists independent of OS, to be able to exclude librt on Android builds, even though it is a 'Linux'.
Sascha Cunz 4bc94eb5 2014-01-30T03:01:46 We never search for libiconv via pkg-config So we actually also never know that we can set a dependency on it in pkg-config. Instead always give it the -L and -l options.
Sascha Cunz 6e0ff093 2014-01-30T02:30:55 Find and use a MacPorts version of libiconv. Fixes #2017. - Add correct -I, -L and -l flags - Search for libiconv in /opt/local/[include|lib] before in the system path. See #2017 for details. - Give splitted -L and -l arguments to pkg-config
Sascha Cunz 60306450 2014-01-29T23:47:20 Use relative path to set cmake module path This has actually no effect on a "normal" build, but allows to use libgit2 as a part of a larger project via CMake's ADD_SUBDIRECTORY() Closes #2087
Sascha Cunz 86f92b74 2014-01-13T12:49:54 Show informational messages during cmake run as informational
Russell Belfer 7697e541 2013-12-11T15:02:20 Test cancel from indexer progress callback This adds tests that try canceling an indexer operation from within the progress callback. After writing the tests, I wanted to run this under valgrind and had a number of errors in that situation because mmap wasn't working. I added a CMake option to force emulation of mmap and consolidated the Amiga-specific code into that new place (so we don't actually need separate Amiga code now, just have to turn on -DNO_MMAP). Additionally, I made the indexer code propagate error codes more reliably than it used to.
Russell Belfer 726b75d1 2013-12-02T11:32:37 Improve iconv finding for cmake * add FindIconv helper for CMake iconv detection * only default using iconv to ON for MacOS * update pkg-config generation to include iconv dependency better
Ben Straub 83e1efbf 2013-11-14T14:10:32 Update files that reference tests-clar
Vicent Martí 0df96f2b 2013-11-10T07:31:21 Merge pull request #1936 from libgit2/better-url-parsing Streamline url-parsing logic.
Vicent Marti 73291aff 2013-11-05T22:08:02 cmake: Add `USE_SSH` option
Ben Straub 2d1feaa2 2013-11-04T15:03:44 Compile HTTP parser on win32 (for url parsing)
Edward Thomson 1bfe7133 2013-10-25T13:23:46 Allow -DWINHTTP=OFF to disable WinHTTP
Carlos Martín Nieto 474c8cf8 2013-10-23T22:49:52 Really fix the pc file It turns out that variables have function scope by default. Let's really set -liconv and add a few libraries that were forgotten in the previous commit. We also need to special-case OSX, as they ship zlib but do not provide a pkg-config file for it.
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.
Russell Belfer 92dac975 2013-10-08T16:35:57 Make reference lookups apply precomposeunicode Before these changes, looking up a reference would return the same precomposed or decomposed form of the reference name that was used to look it up, so on MacOS which ignores the difference between the two, a single reference could be looked up either way and git_reference_name would return the form of the name that was used to look it up! This change makes lookup always return the precomposed name if core.precomposeunicode is set regardless of which version was used to look it up. The reference iterator was already returning the precomposed form from earlier work. This also updates the CMakeLists.txt rules for enabling iconv usage because the clar tests for this code were actually not being activated properly with the old version. Finally, this moves git_repository_reset_filesystem from include/ git2/repository.h to include/git2/sys/repository.h since it is not really a function that normal library users should have to think about very often.
Russell Belfer 219d3457 2013-10-01T16:12:15 Initial iconv hookup for precomposed unicode This hooks up git_path_direach and git_path_dirload so that they will take a flag indicating if directory entry names should be tested and converted from decomposed unicode to precomposed form. This code will only come into play on the Apple platform and even then, only when certain types of filesystems are used. This involved adding a flag to these functions which involved changing a lot of places in the code. This was an opportunity to do a bit of code cleanup here and there, for example, getting rid of the git_futils_cleanupdir_r function in favor of a simple flag to git_futils_rmdir_r to not remove the top level entry. That ended up adding depth tracking during rmdir_r which led to a safety check for infinite directory recursion. Yay. This hasn't actually been tested on the Mac filesystems where the issue occurs. I still need to get test environment for that.
Jameson Miller b176eded 2013-09-19T14:52:57 Initial Implementation of progress reports during push This adds the basics of progress reporting during push. While progress for all aspects of a push operation are not reported with this change, it lays the foundation to add these later. Push progress reporting can be improved in the future - and consumers of the API should just get more accurate information at that point. The main areas where this is lacking are: 1) packbuilding progress: does not report progress during deltafication, as this involves coordinating progress from multiple threads. 2) network progress: reports progress as objects and bytes are going to be written to the subtransport (instead of as client gets confirmation that they have been received by the server) and leaves out some of the bytes that are transfered as part of the push protocol. Basically, this reports the pack bytes that are written to the subtransport. It does not report the bytes sent on the wire that are received by the server. This should be a good estimate of progress (and an improvement over no progress).
Russell Belfer 60ee53df 2013-09-03T15:14:04 Split examples CMakeLists.txt Also, this converts the examples/CMakeLists.txt from explicitly listing to just globbing for all the individual C files.
Vicent Martí c46fe0c6 2013-09-02T03:01:40 Merge pull request #1823 from kadamski/building4android Small changes enabling compiling libgit2 for Android.
Krzysztof Adamski 5c37f005 2013-09-01T18:59:42 Build all example files if BUILD_EXAMPLES used.
Krzysztof Adamski 82b2fc2c 2013-09-01T18:45:36 Create ANDROID build option CMake seems not to support Android as a target and this option lets us test this in CMakeLists.txt.
Russell Belfer 43095341 2013-08-26T14:56:31 Load SRWLock APIs at runtime This loads SRWLock APIs at runtime and in their absence (i.e. on Windows before Vista) falls back on a regular CRITICAL_SECTION that will not permit concurrent readers.
Russell Belfer eb868b1e 2013-08-22T14:34:21 Drop support for THREADSAFE on Windows XP This makes libgit2 require Windows Vista or newer if it is going to be compiled with the THREADSAFE option
Carlos Martín Nieto 5be622fb 2013-08-11T01:37:44 Test SSH in travis Set up the ssh credentials so we are able to talk to localhost and issue git commands. Move to use a script, as the command list is getting somewhat long. While here, delay installing valgrind until we need it, as it and its dependencies are by far the largest downloads and this allows us to start compiling (and failing) faster and we only incur this cost when the test suite runs successfully.
Carlos Martín Nieto d10de8bd 2013-08-12T12:07:33 CMake: finding libssh2 should be idempotent With the current code, running 'cmake .' in an already-configured directory causes the removal of ssh flags passed to the compiler, making it impossible to build with ssh support but by removing CMake's cache. Remove the check for LIBSSH2_LIBRARY and let CMake do the right thing wrt finding the library.
Russell Belfer e8242022 2013-08-05T09:59:02 Move slow tests to "stress" clar module Create a new section of clar tests "stress" that will default to being off where we can put slow tests that push the library for performance testing purposes.
Ben Straub 275d8d55 2013-07-18T09:37:59 Typo
Ben Straub e49dc687 2013-07-17T14:06:31 Switch default calling convention to cdecl.
Edward Thomson cdacd3d9 2013-07-12T16:53:00 header files show up in vs
Thomas Rast c41281ad 2013-06-19T13:36:59 CMakeLists: fix zlib linker setup b53671a (Search for zlib unconditional, 2012-12-18) changed things around to always (even on windows, that's what the subject refers to) call FIND_PACKAGE(ZLIB). However, it did not correctly handle the case where ZLIB_LIBRARY is cached, either by the user setting it manually or by an earlier search. In that case, the IF(ZLIB_FOUND) would not trigger (that variable is not cached) and we'd instead use the built-in version. 000e689 (CMake: don't try to use bundled zlib when the system's path is in the cache, 2013-05-12) tried to fix that, but it actually made the problem worse: now with ZLIB_LIBRARY cached, _neither_ of the blocks would execute, resulting in a linker error for me when trying to build such a doubly-configured setup. To fix the issue, we just trust CMake to do the right thing. If ZLIB_LIBRARY is set (either from user or cache) then the find_library in FindZLIB.cmake will use that instead of searching again. So we can unconditionally (for real this time) call FIND_PACKAGE(ZLIB), and just check its result.
nulltoken c1cf1af4 2013-06-12T21:15:58 cmake: Add option to specify the name of the binary
Vicent Marti 5a6e45cc 2013-06-12T21:14:04 Revert "cmake: Update Windows resources to reflect the optional vendor string" This reverts commit 095bfd748766966f5515bdfe64867d6a09287123.
Veeti Paananen 7a6e0281 2013-05-02T14:07:22 Build with the system's http-parser installation if available
nulltoken 095bfd74 2013-05-21T11:38:24 cmake: Update Windows resources to reflect the optional vendor string Make InternalName and OriginalFilename resources reflect the name of the compiled binary.
nulltoken ccf1a2ba 2013-05-21T11:37:13 cmake: Fix indentation
Vicent Martí e3107e0e 2013-05-16T11:35:02 Merge pull request #1558 from bmorganpa/ssh_transport SSH Transport
Carlos Martín Nieto 3bbc87d6 2013-05-14T23:09:26 CMake: allow appending a string to the library filename This helps us install multiple versions of the library side-by-side.
Carlos Martín Nieto 000e6896 2013-05-12T15:35:02 CMake: don't try to use bundled zlib when the system's path is in the cache The code surrounding zlib bundling did not take into consideration that ZLIB_LIBRARY gets cached, and assumed that FIND(ZLIB) would always set ZLIB_FOUND, which does not hold true, as this variable signifies that we have found the package and had to look at the system, as its location was not cached. Only use the bundled sources if the external zlib is neither newly-found nor cached.
Brad Morgan 00e43380 2013-05-07T14:30:35 Merge remote-tracking branch 'origin/development' into ssh_transport
Brad Morgan 7369b3c3 2013-05-07T14:26:33 Added libssh2 cmake module
Vicent Marti b641c00e 2013-05-03T17:35:50 clar: Always generate the test suite
Edward Thomson ac1d85cf 2013-04-29T11:00:05 cmake 2.6 parser bug workaround
Edward Thomson eb63fda2 2013-04-25T11:52:17 git_atomic_ssize for 64-bit atomics only on 64-bit platforms
Ben Straub ec7e240b 2013-04-09T05:07:12 Add rev-list example to makefiles
Philip Kelley 2c7f7a66 2013-03-25T17:35:36 http: Support 302 Found (arrbee did most of the work)
Vicent Marti c2ea65ee 2013-03-25T21:22:57 clar: Disable online tests. By now.
QbProg d66a7c06 2013-03-16T17:48:24 Fix for a cmake bug when using MSVC + Win64 + static libraries (see http://public.kitware.com/Bug/view.php?id=11240)
QbProg 08f32085 2013-03-16T17:38:27 Adds an option to select the CRT link mode ( static or dynamic ). This is useful when linking libgit2 statically, as the setting must match the linking program's one.
Carlos Martín Nieto 0887b580 2013-03-08T15:13:25 Use C99 stdio in mingw-w64 MinGW >= 3.14 does this automatically, but mingw-64 wants us to define it.
Vicent Martí 92ebbe99 2013-03-07T12:06:18 Merge pull request #1399 from nathan-osman/development Add SONAME build option to facilitate building for Android.
Edward Thomson b5ec5430 2013-03-04T23:52:30 optional tracing
Nathan Osman e7da9acd 2013-03-06T17:51:38 Added build option SONAME to control whether VERSION and SOVERSION were set for the git2 target, as some platforms require that this NOT be set.