Some possibilities:
If your project is, itself, a Git repo (GitHub or otherwise), make the C library a submodule.
git submodule add --name clib git@github.com:someone/clib ./src/clib
Alternatively, perhaps use drakma
or your favored HTTP client (even, perhaps, shelling out to curl
or wget
) to pull a tarball of the sources down from GitHub instead of cloning. (Assuming you're only interested in building, and not editing, the package.)
Run the entire checkout-and-build process from a Makefile
. inferior-shell
may be doable; I typically use uiop:run-program
since ASDF provides it, and just call out to make
.
```
all: src/clib/lib/libclib.so
src/clib/lib/libclib.so: src/clib/Makefile
$(MAKE) -C src/clib all
src/clib/Makefile: src/clib/configure
cd src/clib; ./configure
src/clib/configure: src/clib/configure.in
cd src/clib; autoconf
src/clib/configure.in:
git clone https://github.com/someone/clib ./src/clib
```
You didn't mention what error you're getting from git clone
, but I'm going to guess that it's expecting user input (eg, perhaps to unlock your SSH keychain). Assuming it's a public-visible project, you might do better to use the https:
URI rather than SSH (git@github.com:
) version.