Commit Graph

14 Commits

Author SHA1 Message Date
lhchavez 26edffd5f5 Update CI configuration
This change:

* Updates the GitHub actions so that they run different commands for the
  dynamic and static flavors of libgit2.
* Updates the .travis.yml file so that it does roughly the same as the
  GitHub actions.
* Adds the release-* branches to the CI configurations.
2020-02-22 18:21:38 -08:00
lhchavez aa802a90db
Merge pull request #503 from jonEbird/static-build-script-cleanup
script/build-libgit2-static.sh: correctly set ROOT
2020-02-12 16:57:53 -08:00
Carlos Martín Nieto 57ab6bc351 script: tell libgit2 to use the builtin regex backend 2019-08-13 20:15:01 +02:00
Jon Miller 13090d85b4 script/build-libgit2-static.sh: correctly set ROOT
The ROOT variable is not being set correctly. Need to use dirname against
$0 as well as only go up one directory instead of two.
2019-05-07 11:36:34 -04:00
lhchavez f3c487966d Improve the static build script
This change:

* Uses the installed version of both the library and the pkgconfig file,
  which fixes path resolution on Ubuntu Xenial.
* Uses quoting liberally so that paths with spaces in them are correctly
  handled.
* Moves the build+install directories to static-build/ in the git2go
  repository to avoid having a dirty vendor/libgit2 checkout.
2019-01-05 20:28:35 +00:00
Ryan Graham b3256d9058
static: use pkg-config exclusively when using it
When using the static linking option on platforms that use pkg-config,
use ONLY pkg-config to get the CFLAGS and LDFLAGS. This prevents pulling
in dependencies and flags for any non-vendored version that may be
present on the host.

The main practical effect of this is that if someone doesn't need/want
any sort of remote access support at all they can completely disable
libcurl, libssh2, libssl, etc and produce a smaller/simpler binary and
greatly simplify their build-time dependencies. When done properly, the
generated pkg-config file will tell cgo everything it needs to know.

This also prevents confusion if there is a system copy of libgit2 that
is being given priority over the vendored build.

Signed-off-by: Ryan Graham <r.m.graham@gmail.com>
2018-08-23 10:45:27 -07:00
Carlos Martín Nieto ef83908059 Revert "Make the cgo tool do more linking work" 2014-12-31 19:43:20 +00:00
Carlos Martín Nieto 8f6e13bd08 Make the cgo tool do more linking work
The cgo directives let us do a lot more than I previously thought, so we
can use this to make the building process of git2go go through the go
tool directly rather than via the script.

libgit2 still needs to be built manually, so we do still require make,
but only for building libgit2. Once that's built, any modifications to
git2go's own code can be built with

    go build
2014-12-27 10:59:19 +00:00
Matthias Kadenbach c1ed1bc545 Make sure install/lib dir exists. Fixes #104 2014-08-06 04:07:15 +02:00
Carlos Martín Nieto a2b14b5be4 Tighten up the build
Build as release, and there is no need to install the library, we know
where the files are.
2014-06-07 19:12:33 +02:00
Carlos Martín Nieto aabeb7f585 Really build statically 2014-06-07 15:43:05 +02:00
Carlos Martín Nieto c734fc2a6b Use a submodule for libgit2
This makes building the static version easier as we know where the repo
is and that it's has a known-good version.
2014-06-07 03:03:04 +02:00
Carlos Martín Nieto 0646294282 Move some logic into the Makefile
This should provide a nice compromise between the scripts and comon
commands.
2014-06-03 18:35:09 +02:00
Carlos Martín Nieto de4f42f476 Add scripts to build and use a static libgit2 2014-06-03 12:03:00 +02:00