summaryrefslogtreecommitdiff
path: root/intro2-tour
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2018-05-09 15:13:05 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2018-05-09 15:13:05 +0200
commit4d18b3968b7b18b7da63da5a35733df638c744c0 (patch)
tree8b6651173b33415cc1206e1f07eb3a20b3f4e80e /intro2-tour
parentdc7f3cd85d61ca7af6a935c30b32d71026efdffe (diff)
Add commands for Unpackaged Dependencies section to intro2-tour
Diffstat (limited to 'intro2-tour')
-rwxr-xr-xintro2-tour30
1 files changed, 30 insertions, 0 deletions
diff --git a/intro2-tour b/intro2-tour
index d9ef011..2a2c8bc 100755
--- a/intro2-tour
+++ b/intro2-tour
@@ -163,6 +163,36 @@ show bdep status -r
show bdep status -o libhello
show bdep sync libhello/1.0.0
+# Unpackaged Dependencies.
+#
+cd ..
+rm -rf libextra libextra-gcc unpkg-gcc hello-gcc-1
+show bdep new -C libextra-gcc -t lib -l c++ libextra cc config.cxx=$gcc
+show b install: libextra/ config.install.root=/tmp/unpkg-gcc
+show tree unpkg-gcc
+cd hello
+
+show bdep init -C ../hello-gcc-1 @gcc1 cc config.cxx=$gcc \
+config.cc.poptions=-I$tmp/unpkg-gcc/include \
+config.cc.loptions=-L$tmp/unpkg-gcc/lib
+
+sed -i -re 's/^libs =/import libs = libextra%lib{extra}/' hello/buildfile
+cat <<EOF >>hello/hello.cxx
+#include <libextra/extra.hxx>
+
+void f ()
+{
+ extra::say_hello (cout, "Extra");
+}
+EOF
+
+show b test: ../hello-gcc-1/
+
+show b configure: ../hello-gcc/ \
+config.cc.poptions+=-I$tmp/unpkg-gcc/include \
+config.cc.loptions+=-L$tmp/unpkg-gcc/lib
+show b test
+
# Versioning and Release Management.
#
git add .