forked from eLvErDe/museek-plus
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request eLvErDe#17 from flv0/cmake-cleanup
Cmake cleanup
- Loading branch information
Showing
13 changed files
with
603 additions
and
732 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
project(Mucipher CXX) | ||
set(MUCIPHER_SOURCES | ||
aes.cpp | ||
hexdigest.cpp | ||
md5.cpp | ||
sha.cpp | ||
sha256.cpp | ||
) | ||
aes.cpp | ||
hexdigest.cpp | ||
md5.cpp | ||
sha.cpp | ||
sha256.cpp | ||
) | ||
add_library(Mucipher STATIC ${MUCIPHER_SOURCES}) | ||
|
||
if (PYMUCIPHER) | ||
add_subdirectory(PyMucipher) | ||
else (PYMUCIPHER) | ||
MESSAGE("!!! PyMucipher will NOT be installed.. [NO_PYMUCIPHER=0]") | ||
endif (PYMUCIPHER) | ||
if(PYMUCIPHER) | ||
add_subdirectory(PyMucipher) | ||
else() | ||
message("!!! PyMucipher will NOT be installed.") | ||
endif() | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,26 @@ | ||
project(Muhelp CXX) | ||
|
||
INCLUDE(FindPkgConfig REQUIRED) | ||
include(FindPkgConfig REQUIRED) | ||
|
||
pkg_search_module(LIBXMLPP REQUIRED "libxml++-2.6") | ||
|
||
ADD_DEFINITIONS(${LIBXMLPP_CFLAGS}) | ||
|
||
add_definitions(${LIBXMLPP_CFLAGS}) | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") | ||
|
||
INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BUILD_DIR}) | ||
include_directories(${CMAKE_CURRENT_BUILD_DIR}) | ||
|
||
set(MUHELP_SOURCES | ||
Codec.cc | ||
DirEntry.cc | ||
Muconf.cc | ||
) | ||
Codec.cc | ||
DirEntry.cc | ||
Muconf.cc | ||
) | ||
|
||
add_library(Muhelp STATIC ${MUHELP_SOURCES}) | ||
|
||
# Link the Muhelp library to some libraries. | ||
target_link_libraries( | ||
Muhelp | ||
NewNet | ||
${LIBXML2_LIBRARIES} | ||
${LIBXMLPP_LIBRARIES} | ||
) | ||
Muhelp | ||
NewNet | ||
${LIBXML2_LIBRARIES} | ||
${LIBXMLPP_LIBRARIES} | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,58 +1,50 @@ | ||
project(Mucous) | ||
|
||
|
||
IF(PREFIX) | ||
SET(CMAKE_INSTALL_PREFIX ${PREFIX}) | ||
ELSE(PREFIX) | ||
SET(CMAKE_INSTALL_PREFIX "/usr") | ||
ENDIF(PREFIX) | ||
|
||
|
||
if (NOT MANDIR) | ||
set(MANUAL_DIRECTORY "man/man1") | ||
else (NOT MANDIR) | ||
set(MANUAL_DIRECTORY ${MANDIR}/man1) | ||
endif (NOT MANDIR) | ||
|
||
# add_subdirectory(pymucous) | ||
set(MUCOUS_SOURCES | ||
mucous | ||
) | ||
|
||
mucous | ||
) | ||
|
||
project(Pymucous) | ||
|
||
file(GLOB_RECURSE PYMUCOUS_FILES pymucous/*.py) | ||
|
||
set(PYMUCOUS_SOURCES | ||
${PYMUCOUS_FILES} | ||
) | ||
${PYMUCOUS_FILES} | ||
) | ||
|
||
EXECUTE_PROCESS(COMMAND python ${CMAKE_SOURCE_DIR}/cmake/get_python_lib.py museek OUTPUT_VARIABLE sitepackages OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_VARIABLE error) | ||
execute_process(COMMAND python | ||
${CMAKE_SOURCE_DIR}/cmake/get_python_lib.py museek | ||
OUTPUT_VARIABLE sitepackages | ||
OUTPUT_STRIP_TRAILING_WHITESPACE | ||
ERROR_VARIABLE error) | ||
|
||
if (NOT sitepackages OR error) | ||
MESSAGE(FATAL_ERROR "Failed to find Python's site-packages directory" ${sitepackages} ${error}) | ||
endif (NOT sitepackages OR error) | ||
if(NOT sitepackages OR error) | ||
message(FATAL_ERROR | ||
"Failed to find Python's site-packages directory" | ||
${sitepackages} ${error}) | ||
endif() | ||
|
||
install( | ||
FILES ${PYMUCOUS_SOURCES} | ||
DESTINATION ${CMAKE_INSTALL_PREFIX}/${sitepackages}/pymucous | ||
) | ||
FILES ${PYMUCOUS_SOURCES} | ||
DESTINATION ${CMAKE_INSTALL_PREFIX}/${sitepackages}/pymucous | ||
) | ||
|
||
|
||
# Install the muscan binary to the 'bin' directory. | ||
install( | ||
FILES ${MUCOUS_SOURCES} | ||
DESTINATION bin | ||
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE | ||
) | ||
FILES ${MUCOUS_SOURCES} | ||
DESTINATION bin | ||
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE | ||
GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE | ||
) | ||
|
||
set(MANPAGES | ||
mucous.1 | ||
) | ||
mucous.1 | ||
) | ||
|
||
install( | ||
FILES ${MANPAGES} | ||
DESTINATION ${MANUAL_DIRECTORY} | ||
) | ||
MESSAGE("--> Mucous will be installed..") | ||
FILES ${MANPAGES} | ||
DESTINATION "${CMAKE_INSTALL_MANDIR}/man1" | ||
) | ||
message("--> Mucous will be installed.") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,73 +1,60 @@ | ||
project(Murmur) | ||
|
||
IF(PREFIX) | ||
SET(CMAKE_INSTALL_PREFIX ${PREFIX}) | ||
ELSE(PREFIX) | ||
SET(CMAKE_INSTALL_PREFIX "/usr") | ||
ENDIF(PREFIX) | ||
|
||
|
||
if (NOT MANDIR) | ||
set(MANUAL_DIRECTORY "man/man1") | ||
else (NOT MANDIR) | ||
set(MANUAL_DIRECTORY ${MANDIR}/man1) | ||
endif (NOT MANDIR) | ||
|
||
set(MURMUR_SOURCES | ||
murmur | ||
) | ||
murmur | ||
) | ||
|
||
project(Pymurmur) | ||
|
||
file(GLOB_RECURSE PYMURMUR_FILES pymurmur/*.py) | ||
|
||
set(PYMURMUR_SOURCES | ||
${PYMURMUR_FILES} | ||
) | ||
${PYMURMUR_FILES} | ||
) | ||
|
||
EXECUTE_PROCESS(COMMAND python ${CMAKE_SOURCE_DIR}/cmake/get_python_lib.py museek OUTPUT_VARIABLE sitepackages OUTPUT_STRIP_TRAILING_WHITESPACE ERROR_VARIABLE error) | ||
|
||
if (NOT sitepackages OR error) | ||
MESSAGE(FATAL_ERROR "Failed to find Python's site-packages directory" ${sitepackages} ${error}) | ||
endif (NOT sitepackages OR error) | ||
if(NOT sitepackages OR error) | ||
message(FATAL_ERROR "Failed to find Python's site-packages directory" ${sitepackages} ${error}) | ||
endif() | ||
|
||
install( | ||
FILES ${PYMURMUR_SOURCES} | ||
DESTINATION ${CMAKE_INSTALL_PREFIX}/${sitepackages}/pymurmur | ||
) | ||
FILES ${PYMURMUR_SOURCES} | ||
DESTINATION ${CMAKE_INSTALL_PREFIX}/${sitepackages}/pymurmur | ||
) | ||
|
||
|
||
# Install the murmur binary to the 'bin' directory. | ||
install( | ||
FILES ${MURMUR_SOURCES} | ||
DESTINATION bin | ||
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE | ||
) | ||
FILES ${MURMUR_SOURCES} | ||
DESTINATION bin | ||
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE | ||
) | ||
set(MANPAGES | ||
murmur.1 | ||
) | ||
murmur.1 | ||
) | ||
|
||
install( | ||
FILES ${MANPAGES} | ||
DESTINATION ${MANUAL_DIRECTORY} | ||
) | ||
FILES ${MANPAGES} | ||
DESTINATION "${CMAKE_INSTALL_MANDIR}/man1" | ||
) | ||
set(ICONS | ||
images/murmur-96px.png | ||
images/murmur-64px.png | ||
images/murmur-32px.png | ||
images/murmur-16px.png | ||
) | ||
images/murmur-96px.png | ||
images/murmur-64px.png | ||
images/murmur-32px.png | ||
images/murmur-16px.png | ||
) | ||
|
||
install( | ||
FILES ${ICONS} | ||
DESTINATION "share/pixmaps" | ||
) | ||
FILES ${ICONS} | ||
DESTINATION "share/pixmaps" | ||
) | ||
set(DESKTOP | ||
files/murmur.desktop | ||
) | ||
files/murmur.desktop | ||
) | ||
|
||
install( | ||
FILES ${DESKTOP} | ||
DESTINATION "share/applications" | ||
) | ||
MESSAGE("--> Murmur will be installed..") | ||
FILES ${DESKTOP} | ||
DESTINATION "share/applications" | ||
) | ||
message("--> Murmur will be installed.") |
Oops, something went wrong.