aboutsummaryrefslogtreecommitdiffstats
path: root/template.d/autobuild
diff options
context:
space:
mode:
authorRomain Forlot <romain.forlot@iot.bzh>2017-09-15 14:37:43 +0200
committerRomain Forlot <romain.forlot@iot.bzh>2017-09-15 14:37:43 +0200
commit9116b93f53127e48f3821497440500b6b78989c6 (patch)
tree3e96fe2740f7b3efc8dceecf9d854aeb99b6b5d6 /template.d/autobuild
parent908a0372d53c74a037da3debe1e276a214343c41 (diff)
Adding install target to autobuild script
Change-Id: I1ee2fb376e247c74e383428ec5c0b7994cba1f54 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
Diffstat (limited to 'template.d/autobuild')
-rwxr-xr-xtemplate.d/autobuild/agl/autobuild.in8
-rwxr-xr-xtemplate.d/autobuild/linux/autobuild.in8
2 files changed, 11 insertions, 5 deletions
diff --git a/template.d/autobuild/agl/autobuild.in b/template.d/autobuild/agl/autobuild.in
index 4811441..3a1ba5f 100755
--- a/template.d/autobuild/agl/autobuild.in
+++ b/template.d/autobuild/agl/autobuild.in
@@ -29,8 +29,9 @@ help:
@echo "- clean"
@echo "- distclean"
@echo "- configure"
- @echo "- build"
- @echo "- package"
+ @echo "- build: compilation, link and prepare files for package into a widget"
+ @echo "- package: output a widget file '*.wgt'"
+ @echo "- install: install in your ${CMAKE_INSTALL_DIR} directory"
@echo ""
@echo "Usage: ./conf.d/autobuild/agl/autobuild package DEST=${HOME}/opt"
@echo "Don't use your build dir as DEST as wgt file is generated at this location"
@@ -58,6 +59,9 @@ package: build
@cmake --build ${BUILD_DIR} --target widget
@mkdir -p ${DEST} && cp ${BUILD_DIR}/*wgt ${DEST}
+install: build
+ @cmake --build ${BUILD_DIR} --target install
+
${BUILD_DIR}/Makefile:
@[ -d ${BUILD_DIR} ] || mkdir -p ${BUILD_DIR}
@[ -f ${BUILD_DIR}/Makefile ] || (cd ${BUILD_DIR} && cmake ${CONFIGURE_ARGS} ..)
diff --git a/template.d/autobuild/linux/autobuild.in b/template.d/autobuild/linux/autobuild.in
index 0b6f06c..3a1ba5f 100755
--- a/template.d/autobuild/linux/autobuild.in
+++ b/template.d/autobuild/linux/autobuild.in
@@ -29,8 +29,9 @@ help:
@echo "- clean"
@echo "- distclean"
@echo "- configure"
- @echo "- build"
- @echo "- package"
+ @echo "- build: compilation, link and prepare files for package into a widget"
+ @echo "- package: output a widget file '*.wgt'"
+ @echo "- install: install in your ${CMAKE_INSTALL_DIR} directory"
@echo ""
@echo "Usage: ./conf.d/autobuild/agl/autobuild package DEST=${HOME}/opt"
@echo "Don't use your build dir as DEST as wgt file is generated at this location"
@@ -55,10 +56,11 @@ package: build
@mkdir -p ${BUILD_DIR}/$@/lib
@mkdir -p ${BUILD_DIR}/$@/htdocs
@mkdir -p ${BUILD_DIR}/$@/data
- @cmake --build ${BUILD_DIR} --target packaging
@cmake --build ${BUILD_DIR} --target widget
@mkdir -p ${DEST} && cp ${BUILD_DIR}/*wgt ${DEST}
+install: build
+ @cmake --build ${BUILD_DIR} --target install
${BUILD_DIR}/Makefile:
@[ -d ${BUILD_DIR} ] || mkdir -p ${BUILD_DIR}