diff --git a/CMakeLists.txt b/CMakeLists.txt index bded0f8..7e99959 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -72,9 +72,10 @@ install(CODE ]] ) -install( - CODE "execute_process(COMMAND ${CMAKE_INSTALL_PREFIX}/bin/pipedalconfig --install)" -) +# Should be done by install.sh instead of here so that we can build the package without root permissions. +# install( +# CODE "execute_process(COMMAND ${CMAKE_INSTALL_PREFIX}/bin/pipedalconfig --install)" +# ) set(CPACK_GENERATOR "DEB") diff --git a/docs/TheBuildSystem.md b/docs/TheBuildSystem.md index fa06939..7f69410 100644 --- a/docs/TheBuildSystem.md +++ b/docs/TheBuildSystem.md @@ -13,14 +13,14 @@ available through the Code plugins store) has configured itself, build commands If you are not using Visual Studio Code, you can configure, build and install PiPedal using CMake build tools. For your convenience, the following shell scripts have been provided in the root of the project. - ./init # Configure the CMake build (first time, or if you - # have changed one of the CMakeList.txt files) + ./init.sh # Configure the CMake build for the first time, or if you + # have changed one of the CMakeList.txt files. (release build) - ./mk # Build all targets. + ./mk.sh # Build all targets (release build) - sudo ./install # Deploy all targets + sudo ./install.sh # Deploy all targets - sudo ./makePackage # Build a .deb file for distribution. + sudo ./makePackage.sh # Build a .deb file for distribution. If you are using a development environment other than Visual Studio Code, it should be fairly straightforward to figure out how to incorporate the PiPedal build procedure into your IDE workflow by using the contents of the build shell scripts as a model. diff --git a/init b/init.sh similarity index 100% rename from init rename to init.sh diff --git a/install b/install deleted file mode 100755 index 7f3db98..0000000 --- a/install +++ /dev/null @@ -1 +0,0 @@ -cmake --install build --prefix /usr --config Release -v diff --git a/install.sh b/install.sh new file mode 100755 index 0000000..c4f0fbe --- /dev/null +++ b/install.sh @@ -0,0 +1,5 @@ +#!/usr/bin/bash +# copy files. +cmake --install build --prefix /usr --config Release -v +# Done as an install action by the debian package. +sudo /usr/bin/pipedalconfig --install diff --git a/makePackage b/makePackage.sh similarity index 100% rename from makePackage rename to makePackage.sh diff --git a/mk b/mk.sh similarity index 100% rename from mk rename to mk.sh