From 17a2cd72bac228a7cdcd91ce2a4a1d58d8aa8d0a Mon Sep 17 00:00:00 2001 From: Alessandro Iezzi Date: Mon, 29 May 2023 22:12:45 +0200 Subject: Add target to copy includes in build directory --- Makefile | 8 ++++++-- scripts/buildmk.sh | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 4acbd40..4dcf9d2 100644 --- a/Makefile +++ b/Makefile @@ -15,9 +15,9 @@ dist: all cp ${BUILD_DIR}/release/shared/${LIBNAME:=.so} ${DIST_DIR}/ cp ${INCLUDES} ${DIST_DIR}/include/cherry -debug: debug-static debug-shared +debug: debug-static debug-shared copy-includes -release: static shared +release: static shared copy-includes static: @make BUILD_DIR=${BUILD_DIR}/release/static ${BUILD_DIR}/release/static/${LIBNAME:=.a} @@ -28,6 +28,10 @@ shared: debug-static: @make BUILD_DIR=${BUILD_DIR}/debug/static OPT=-g ${BUILD_DIR}/debug/static/${LIBNAME:=.a} +copy-includes: + @mkdir -p ${BUILD_DIR}/include/cherry + @cp ${INCLUDES} ${BUILD_DIR}/include/cherry + debug-shared: @make BUILD_DIR=${BUILD_DIR}/debug/shared OPT="-g -fPIC" ${BUILD_DIR}/debug/shared/${LIBNAME:=.so} diff --git a/scripts/buildmk.sh b/scripts/buildmk.sh index c94e2e2..3356382 100755 --- a/scripts/buildmk.sh +++ b/scripts/buildmk.sh @@ -30,9 +30,9 @@ dist: all cp \${BUILD_DIR}/release/shared/\${LIBNAME:=.so} \${DIST_DIR}/ cp \${INCLUDES} \${DIST_DIR}/include/cherry -debug: debug-static debug-shared +debug: debug-static debug-shared copy-includes -release: static shared +release: static shared copy-includes static: @make BUILD_DIR=\${BUILD_DIR}/release/static \${BUILD_DIR}/release/static/\${LIBNAME:=.a} @@ -43,6 +43,10 @@ shared: debug-static: @make BUILD_DIR=\${BUILD_DIR}/debug/static OPT=-g \${BUILD_DIR}/debug/static/\${LIBNAME:=.a} +copy-includes: + @mkdir -p \${BUILD_DIR}/include/cherry + @cp \${INCLUDES} \${BUILD_DIR}/include/cherry + debug-shared: @make BUILD_DIR=\${BUILD_DIR}/debug/shared OPT="-g -fPIC" \${BUILD_DIR}/debug/shared/\${LIBNAME:=.so} -- cgit v1.2.3