diff --git a/bin/lambda3.in b/bin/lambda3.in deleted file mode 100644 index a66c5b791..000000000 --- a/bin/lambda3.in +++ /dev/null @@ -1,51 +0,0 @@ -#!/bin/sh - -CURDIR="$(readlink -f $(dirname "$0"))/" -SYSTEM_BIN_DIR="@CMAKE_INSTALL_FULL_BINDIR@/" - -if [ "${CURDIR}" = "${SYSTEM_BIN_DIR}" ]; then # we are installed - PREFIX="@CMAKE_INSTALL_FULL_LIBEXECDIR@" -else # we are just unpacked - PREFIX="${CURDIR}/../@CMAKE_INSTALL_LIBEXECDIR@" -fi - -BIN=${PREFIX}/lambda3 - -# no is the default -HAS_CPU_EXT=0 - -case $(uname) in - "Linux") - grep -E "flags.* popcnt " -q /proc/cpuinfo 2>/dev/null && \ - grep -E "flags.* sse4_1 " -q /proc/cpuinfo 2>/dev/null && \ - grep -E "flags.* sse4_2 " -q /proc/cpuinfo 2>/dev/null && \ - export HAS_CPU_EXT=1 - ;; - "FreeBSD") - grep -E "Feature.*POPCNT" -q /var/run/dmesg.boot 2>/dev/null && \ - grep -E "Feature.*SSE4\.1" -q /var/run/dmesg.boot 2>/dev/null && \ - grep -E "Feature.*SSE4\.2" -q /var/run/dmesg.boot 2>/dev/null && \ - export HAS_CPU_EXT=1 - ;; -## OpenBSD doesn't yet support POPCNT software side (although it does detect the cpu feature) -# "OpenBSD") -# grep -E "cpu.*POPCNT" -q /var/run/dmesg.boot 2>/dev/null && \ -# grep -E "cpu.*SSE4\.1" -q /var/run/dmesg.boot 2>/dev/null && \ -# grep -E "cpu.*SSE4\.2" -q /var/run/dmesg.boot 2>/dev/null && \ -# export HAS_CPU_EXT=1 -# ;; - "Darwin") - sysctl machdep.cpu.features 2>&1 | grep -E "POPCNT" -q 2>/dev/null && \ - sysctl machdep.cpu.features 2>&1 | grep -E "SSE4\.1" -q 2>/dev/null && \ - sysctl machdep.cpu.features 2>&1 | grep -E "SSE4\.2" -q 2>/dev/null && \ - export HAS_CPU_EXT=1 - ;; - *) - ;; -esac - -if [ $HAS_CPU_EXT -eq 0 ]; then - echo "Your CPU does not meet Lambda's minimum requirements. The app might crash." >&2 -fi - -exec "${BIN}" "${@}" diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 20c0f5a09..a7c70782d 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -58,11 +58,6 @@ message( " LAMBDA_WITH_BIFM ${LAMBDA_WITH_BIFM}") message(STATUS "Run 'cmake -LH' to get a comment on each option.") message(STATUS "Remove CMakeCache.txt and re-run cmake with -DOPTIONNAME=ON|OFF to change an option.") -# deactivate the version check on broken seqan releases -if (SEQAN_VERSION_STRING VERSION_LESS "2.3.2") - add_definitions (-DSEQAN_DISABLE_VERSION_CHECK="YES") -endif () - # ---------------------------------------------------------------------------- # Dependencies (continued) # ---------------------------------------------------------------------------- @@ -130,7 +125,7 @@ if (CMAKE_CXX_COMPILER_ID MATCHES "GNU") ProcessorCount(LAMBDA_COMPILE_THREADS) endif () - # This triggers an ICE for some reason + # TODO: this should be fixed; currently triggers an ICE for some reason # if (LAMBDA_COMPILE_THREADS GREATER 1) # set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -flto=${LAMBDA_COMPILE_THREADS}") # endif() @@ -139,11 +134,6 @@ if (CMAKE_CXX_COMPILER_ID MATCHES "GNU") set (CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -s") endif () -if (NOT CMAKE_CXX_COMPILER_ID MATCHES "Intel") - # -Wextra not met by current SeqAn on intel - set (SEQAN_CXX_FLAGS "${SEQAN_CXX_FLAGS} -Wextra") -endif () - # ---------------------------------------------------------------------------- # Build Setup # ---------------------------------------------------------------------------- @@ -187,6 +177,12 @@ add_custom_command (OUTPUT lambda3-searchn.1 add_custom_command (OUTPUT lambda3-searchp.1 COMMAND lambda3 searchp --export-help man > lambda3-searchp.1 DEPENDS lambda3) + +# searchbs subcommand +add_custom_command (OUTPUT lambda3-searchbs.1 + COMMAND lambda3 searchbs --export-help man > lambda3-searchbs.1 + DEPENDS lambda3) + # mkindexn subcommand add_custom_command (OUTPUT lambda3-mkindexn.1 COMMAND lambda3 mkindexn --export-help man > lambda3-mkindexn.1 @@ -196,9 +192,14 @@ add_custom_command (OUTPUT lambda3-mkindexp.1 COMMAND lambda3 mkindexp --export-help man > lambda3-mkindexp.1 DEPENDS lambda3) -add_custom_target (manual - ALL - DEPENDS lambda3.1 lambda3-searchn.1 lambda3-searchp.1 lambda3-mkindexn.1 lambda3-mkindexp.1) +# mkindexbs subcommand +add_custom_command (OUTPUT lambda3-mkindexbs.1 + COMMAND lambda3 mkindexbs --export-help man > lambda3-mkindexbs.1 + DEPENDS lambda3) + +add_custom_target (manual ALL DEPENDS lambda3.1 + lambda3-searchn.1 lambda3-searchp.1 lambda3-searchbs.1 + lambda3-mkindexn.1 lambda3-mkindexp.1 lambda3-mkindexbs.1) # ---------------------------------------------------------------------------- # Installation @@ -209,16 +210,7 @@ include (GNUInstallDirs) # Install lambda binaries into LIBEXECDIR install (TARGETS lambda3 - DESTINATION ${CMAKE_INSTALL_LIBEXECDIR}) - -# Install dispatcher script into BINDIR -configure_file(../bin/lambda3.in - ${CMAKE_CURRENT_BINARY_DIR}/lambda3-dispatch - @ONLY) -install (FILES ${CMAKE_CURRENT_BINARY_DIR}/lambda3-dispatch - DESTINATION ${CMAKE_INSTALL_BINDIR} - RENAME lambda3 - PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE) + DESTINATION ${CMAKE_INSTALL_BINDIR}) # Install non-binary files for the package to DOCDIR, usually ${PREFIX}/share/doc/lambda3 install (FILES ../LICENSE.rst @@ -231,8 +223,10 @@ install (FILES ../LICENSE.rst install (FILES ${CMAKE_CURRENT_BINARY_DIR}/lambda3.1 ${CMAKE_CURRENT_BINARY_DIR}/lambda3-searchn.1 ${CMAKE_CURRENT_BINARY_DIR}/lambda3-searchp.1 + ${CMAKE_CURRENT_BINARY_DIR}/lambda3-searchbs.1 ${CMAKE_CURRENT_BINARY_DIR}/lambda3-mkindexn.1 ${CMAKE_CURRENT_BINARY_DIR}/lambda3-mkindexp.1 + ${CMAKE_CURRENT_BINARY_DIR}/lambda3-mkindexbs.1 DESTINATION ${CMAKE_INSTALL_MANDIR}/man1) # ---------------------------------------------------------------------------- @@ -244,7 +238,7 @@ set (CPACK_PACKAGE_NAME "lambda3") set (CPACK_PACKAGE_DESCRIPTION_SUMMARY "lambda -- the local aligner for massive bioligical data") set (CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/../README.rst") set (CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/../LICENSE.rst") -set (CPACK_PACKAGE_VENDOR "Hannes Hauswedell ") +set (CPACK_PACKAGE_VENDOR "Hannes Hauswedell ") set (CPACK_PACKAGE_CONTACT "${CPACK_PACKAGE_VENDOR}") set (CPACK_PACKAGE_VERSION_MAJOR "${SEQAN_APP_VERSION_MAJOR}") set (CPACK_PACKAGE_VERSION_MINOR "${SEQAN_APP_VERSION_MINOR}")