Commit 001d1d86 authored by Hanspeter Portner's avatar Hanspeter Portner

work on release automation.

parent 64baedf8
......@@ -77,6 +77,7 @@ if(BUILD_COMMON_UI)
target_link_libraries(moony_ui ${LIBS_UI})
set_target_properties(moony_ui PROPERTIES PREFIX "")
install(TARGETS moony_ui DESTINATION ${DEST})
install(FILES ${PROJECT_SOURCE_DIR}/omk_logo_256x256.png DESTINATION ${DEST})
else()
set(EO_UI_WRAP "#")
set(UI_UI_WRAP "#")
......@@ -91,7 +92,11 @@ if(BUILD_SIMPLE_UI)
pkg_search_module(UV REQUIRED libuv>=1.0)
include_directories(${UV_INCLUDE_DIRS})
set(LIBS_SIMPLE ${LIBS_SIMPLE} ${UV_LDFLAGS})
if(DEFINED STATIC_UV)
set(LIBS_SIMPLE ${STATIC_UV} ${LIBS_SIMPLE})
else()
set(LIBS_SIMPLE ${LIBS_SIMPLE} ${UV_LDFLAGS})
endif()
add_library(moony_simple MODULE
moony_simple.c
......@@ -164,7 +169,6 @@ configure_file(${PROJECT_SOURCE_DIR}/manifest.ttl.in ${PROJECT_BINARY_DIR}/manif
install(FILES ${PROJECT_BINARY_DIR}/manifest.ttl DESTINATION ${DEST})
install(FILES ${PROJECT_SOURCE_DIR}/moony.ttl DESTINATION ${DEST})
install(FILES ${PROJECT_SOURCE_DIR}/presets.ttl DESTINATION ${DEST})
install(FILES ${PROJECT_SOURCE_DIR}/omk_logo_256x256.png DESTINATION ${DEST})
include(CTest)
......@@ -228,7 +232,7 @@ if(${BUILD_TESTING})
endif()
# CPack
set(CPACK_GENERATOR "TBZ2;DEB")
set(CPACK_GENERATOR "ZIP")
set(CPACK_PACKAGE_NAME "moony-lv2")
set(CPACK_PACKAGE_VERSION "${MOONY_VERSION}")
......@@ -239,7 +243,7 @@ set(CPACK_PACKAGE_CONTACT "Hanspeter Portner <dev@open-music-kontrollers.ch>")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Realtime Lua as programmable glue in LV2")
SET(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_SOURCE_DIR}/README.md")
SET(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/COPYING")
SET(CPACK_STRIP_FILES "lib/lv2/moony.lv2/moony.so;lib/lv2/moony.lv2/moon_ui.so")
SET(CPACK_STRIP_FILES "lib/lv2/moony.lv2/moony.so;lib/lv2/moony.lv2/moon_ui.so;lib/lv2/moony.lv2/moony_simple.so")
# Debian
set(CPACK_DEBIAN_PACKAGE_NAME ${CPACK_PACKAGE_NAME})
......
# the name of the target operating system
set(CMAKE_SYSTEM_NAME Linux)
set(CMAKE_SYSTEM_PROCESSOR "i686")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m32" CACHE STRING "c++ flags")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -m32" CACHE STRING "c flags")
set(STATIC_UV "/usr/lib32/libuv.a")
# the name of the target operating system
set(CMAKE_SYSTEM_NAME Windows)
set(CMAKE_SYSTEM_PROCESSOR "i686")
set(TOOLCHAIN "i686-w64-mingw32")
# which compilers to use for C and C++
......@@ -17,5 +18,5 @@ set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
set(LIBS_SIMPLE ${LIBS_SIMPLE} "/usr/i686-w64-mingw32/lib/libuv.a")
set(STATIC_UV "/usr/${TOOLCHAIN}/lib/libuv.a")
set(LIBS_SIMPLE ${LIBS_SIMPLE} "-static-libgcc -lws2_32 -lpsapi -liphlpapi -Wl,-Bstatic -lwinpthread -luserenv")
# the name of the target operating system
set(CMAKE_SYSTEM_NAME Linux)
set(CMAKE_SYSTEM_PROCESSOR "x86_64")
set(STATIC_UV "/usr/lib64/libuv.a")
# the name of the target operating system
set(CMAKE_SYSTEM_NAME Windows)
set(CMAKE_SYSTEM_PROCESSOR "x86_64")
set(TOOLCHAIN "x86_64-w64-mingw32")
# which compilers to use for C and C++
......@@ -16,3 +17,6 @@ set(CMAKE_FIND_ROOT_PATH "/usr/${TOOLCHAIN}")
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
set(STATIC_UV "/usr/${TOOLCHAIN}/lib/libuv.a")
set(LIBS_SIMPLE ${LIBS_SIMPLE} "-static-libgcc -lws2_32 -lpsapi -liphlpapi -Wl,-Bstatic -lwinpthread -luserenv")
#/bin/bash
mkdir -p release
pushd release &> /dev/null
#for toolchain in armv7-linux i686-linux i686-w64-mingw32 x86_64-linux x86_64-w64-mingw32;
for toolchain in i686-linux i686-w64-mingw32 x86_64-linux x86_64-w64-mingw32;
do
echo $toolchain
sudo rm -rf $toolchain
mkdir $toolchain
pushd $toolchain &> /dev/null
cmake \
-DCMAKE_TOOLCHAIN_FILE=../../cmake/$toolchain.cmake \
-DBUILD_COMMON_UI=0 \
-DBUILD_SIMPLE_UI=1 \
-DUSE_FS_EVENT=1 \
-DBUILD_TESTING=0 \
-DCPACK_SYSTEM_NAME="$toolchain" \
../..
make
sudo make package
popd &> /dev/null
done
cp */*.zip .
popd &> /dev/null
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment