From 0353c7ae346fbdd88cc1751bf0ffaa6a9d390ae3 Mon Sep 17 00:00:00 2001 From: Oliver Heimlich Date: Fri, 13 Nov 2015 07:34:05 +0100 Subject: [PATCH] Simplified Octave API distribution --- .travis.yml | 1 + client-api/Octave/.gitignore | 1 + client-api/Octave/Makefile | 20 ++++++++++---------- 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/.travis.yml b/.travis.yml index b708928..135bf5e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -28,6 +28,7 @@ before_script: script: - make -C viewer/build + - make -C client-api/Octave - if [ $TRAVIS_OS_NAME == linux ]; then make -C client-api/Octave install; fi after_success: diff --git a/client-api/Octave/.gitignore b/client-api/Octave/.gitignore index f26770e..1f85430 100644 --- a/client-api/Octave/.gitignore +++ b/client-api/Octave/.gitignore @@ -1,4 +1,5 @@ vibes-*.tar.gz +vibes-bundle/** vibes-html/** fntest.log octave-* diff --git a/client-api/Octave/Makefile b/client-api/Octave/Makefile index 4f7a818..86397e7 100644 --- a/client-api/Octave/Makefile +++ b/client-api/Octave/Makefile @@ -37,14 +37,14 @@ dist: $(RELEASE_TARBALL) $(RELEASE_TARBALL): ../../.git/index @echo "Creating package release ..." - @# Export the current subdir of the source repository - @# This is only the Octave API - @git archive --output="$(PACKAGE)-$(VERSION).tar" --prefix="$(PACKAGE)-$(VERSION)/" HEAD @# The C++ API must be bundled - @(cd ../C++/; git archive --output="$(shell pwd)/$(PACKAGE)-deps.tar" --prefix="$(PACKAGE)-$(VERSION)/" HEAD src) - @tar --concatenate --file="$(PACKAGE)-$(VERSION).tar" "$(PACKAGE)-deps.tar" - @$(GZIP) --best -f "$(PACKAGE)-$(VERSION).tar" - @rm -f "$(PACKAGE)-$(VERSION).tar" "$(PACKAGE)-deps.tar" + @rm -rf "$(PACKAGE)-bundle" + @mkdir -p "$(PACKAGE)-bundle" + @git archive --format=tar --prefix="$(PACKAGE)-$(VERSION)/" HEAD | \ + (cd "$(PACKAGE)-bundle" && tar xf -) + @(cd ../C++/; git archive --format=tar --prefix="$(PACKAGE)-$(VERSION)/" HEAD src) | \ + (cd "$(PACKAGE)-bundle" && tar xf -) + @(cd "$(PACKAGE)-bundle" && tar czf "../$@" "$(PACKAGE)-$(VERSION)") ## ## Local Install Process @@ -116,10 +116,10 @@ run: $(INSTALLED_PACKAGE) clean: rm -rf \ - "$(PACKAGE)-*.tar" \ - "$(PACKAGE)-*.tar.gz" \ + $(PACKAGE)-*.tar.gz \ + "$(PACKAGE)-bundle" \ "$(HTML_DIR)" \ "$(HTML_TARBALL)" \ "fntests.log" \ - "octave-*" + octave-*