cmake: move remaining ungrounded entries into LYX_ group

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@34897 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Peter Kümmel 2010-07-14 15:30:31 +00:00
parent 4ab78db6b4
commit 0708686f69
7 changed files with 21 additions and 24 deletions

View File

@ -43,6 +43,7 @@ LYX_OPTION(PACKAGE_SUFFIX "Use version suffix for packaging" ON ALL)
LYX_OPTION(PROGRAM_SUFFIX "Append version suffix to binaries" ON GCC)
LYX_OPTION(NO_CONSOLE "Suppress console on Windows" OFF MSVC)
LYX_OPTION(VLD "Use VLD with MSVC" OFF MSVC)
LYX_OPTION(WALL "Enable all warnings" OFF MSVC)
LYX_OPTION(DISABLE_PCH "Disable precompiled headers" ON ALL)
LYX_OPTION(MERGE_FILES "Merge source files into one compilation unit" OFF ALL)
LYX_OPTION(DEBUG_GLIBC "Enable libstdc++ debug mode" OFF GCC)
@ -80,7 +81,7 @@ if(LYX_INSTALL)
set(LYX_ASPELL ON CACHE BOOL "Aspell option" FORCE)
set(LYX_NLS ON CACHE BOOL "Nls option" FORCE)
SET(LYX_NO_CONSOLE ON CACHE BOOL "No console option" FORCE)
SET(PACKAGE_SUFFIX ON CACHE BOOL "Package suffix option" FORCE)
SET(LYX_PACKAGE_SUFFIX ON CACHE BOOL "Package suffix option" FORCE)
SET(LYX_RELEASE ON CACHE BOOL "Release option" FORCE)
SET(LYX_DEBUG OFF CACHE BOOL "Debug option" FORCE)
SET(LYX_PROFILE OFF CACHE BOOL "Profile option" FORCE)
@ -164,14 +165,14 @@ if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
endif(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
if (WIN32)
set(DATA_SUBDIR "Resources/" CACHE STRING "Subdirectory for all lyx-system-data" FORCE)
set(LYX_DATA_SUBDIR "Resources/" CACHE STRING "Subdirectory for all lyx-system-data" FORCE)
else()
set(DATA_SUBDIR "" CACHE STRING "Subdirectory for all lyx-system-data" FORCE)
set(LYX_DATA_SUBDIR "" CACHE STRING "Subdirectory for all lyx-system-data" FORCE)
endif()
set(LYX_ABS_INSTALLED_DATADIR "${CMAKE_INSTALL_PREFIX}")
set(LYX_LOCALEDIR "locale")
set(LYX_ABS_INSTALLED_LOCALEDIR "${LYX_ABS_INSTALLED_DATADIR}/${DATA_SUBDIR}${LYX_LOCALEDIR}")
set(LYX_ABS_INSTALLED_LOCALEDIR "${LYX_ABS_INSTALLED_DATADIR}/${LYX_DATA_SUBDIR}${LYX_LOCALEDIR}")
set(LYX_ABS_TOP_SRCDIR "${TOP_SRC_DIR}")
@ -375,9 +376,7 @@ if(MSVC)
endif()
# TODO options
if(WALL)
set(WALL 1 CACHE TYPE STRING FORCE)
if(LYX_WALL)
# Use the highest warning level
set(CMAKE_CXX_WARNING_LEVEL 4 CACHE TYPE STRING FORCE)
set(WARNING_LEVEL_MESSAGE "(switch to warning level 3 with -DWALL=0)")
@ -407,8 +406,6 @@ if(MSVC)
"${CMAKE_CXX_FLAGS_MINSIZEREL} /Wp64 ${MSVC_W_ERROR} ${MSVC_W_DISABLE}")
else()
set(WALL 0 CACHE TYPE STRING FORCE)
set(CMAKE_CXX_WARNING_LEVEL 3 CACHE TYPE STRING FORCE)
set(WARNING_LEVEL_MESSAGE "(switch to warning level 4 with -DWALL=1)")
@ -439,9 +436,8 @@ if(MSVC)
endif()
FIND_PROGRAM(_PERL_EXECUTABLE perl)
FIND_PROGRAM(_PYTHON_EXECUTABLE python)
if( NOT ${_PYTHON_EXECUTABLE} MATCHES "-NOTFOUND")
FIND_PROGRAM(LYX_PYTHON_EXECUTABLE python)
if( NOT ${LYX_PYTHON_EXECUTABLE} MATCHES "-NOTFOUND")
if(LYX_NLS)
find_package(LyXGettext REQUIRED)
include_directories(${TOP_SRC_DIR}/po)
@ -505,7 +501,8 @@ add_subdirectory(src)
if(LYX_INSTALL)
add_subdirectory(man)
if(NOT ${_PERL_EXECUTABLE} MATCHES "-NOTFOUND")
FIND_PROGRAM(LYX_PERL_EXECUTABLE python)
if(NOT ${LYX_PERL_EXECUTABLE} MATCHES "-NOTFOUND")
add_subdirectory(doc)
endif()
endif()

View File

@ -43,9 +43,9 @@ macro(lyx_install _parent_src_dir _gl_dir _file_type)
if(_glob_dir STREQUAL ".")
set(_base_dir .)
endif()
#message(STATUS "install ${DATA_SUBDIR}${_dir}/${_base_dir}: ${files_list} ")
#message(STATUS "install at ${CMAKE_INSTALL_PREFIX}/${DATA_SUBDIR}${_dir}/${_base_dir}")
install(FILES ${files_list} DESTINATION ${DATA_SUBDIR}${_dir}/${_base_dir})
#message(STATUS "install ${LYX_DATA_SUBDIR}${_dir}/${_base_dir}: ${files_list} ")
#message(STATUS "install at ${CMAKE_INSTALL_PREFIX}/${LYX_DATA_SUBDIR}${_dir}/${_base_dir}")
install(FILES ${files_list} DESTINATION ${LYX_DATA_SUBDIR}${_dir}/${_base_dir})
endif()
endforeach(_current_dir)
endforeach(_glob_dir)

View File

@ -9,14 +9,14 @@
# #include(../PyCompile)
project(${_project})
include(FindPythonInterp)
FIND_PROGRAM(LYX_PYTHON_EXECUTABLE python)
file(GLOB _py_files ${TOP_SRC_DIR}/lib/${_project}/*.py)
set(py_compile ${TOP_SRC_DIR}/config/py-compile)
set(_generated)
set(ENV{PYTHON} ${PYTHON_EXECUTABLE})
set(ENV{PYTHON} ${LYX_PYTHON_EXECUTABLE})
foreach(_orig_py ${_py_files})
get_filename_component(_base_we_py ${_orig_py} NAME_WE)

View File

@ -32,7 +32,7 @@ foreach(_rel_doc ${_rel_lyx_docs})
COMMAND perl "${CMAKE_SOURCE_DIR}/doc/ReplaceValues.pl" "LYX_USERDIR_VER=${LYX_USERDIR_VER}" "LYX_DIR_VER=${LYX_DIR_VER}" "${TOP_SRC_DIR}/lib/doc/${_rel_doc}" > "${_created_doc}"
DEPENDS "${TOP_SRC_DIR}/lib/doc/${_rel_doc}"
)
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${_rel_doc}" DESTINATION "${DATA_SUBDIR}doc/${_rel_dir_part}")
install(FILES "${CMAKE_CURRENT_BINARY_DIR}/${_rel_doc}" DESTINATION "${LYX_DATA_SUBDIR}doc/${_rel_dir_part}")
LIST(APPEND _docs "${_created_doc}")
endforeach(_rel_doc)

View File

@ -7,11 +7,11 @@
configure_file(${TOP_SRC_DIR}/lib/lyx2lyx/lyx2lyx_version.py.in
${CMAKE_CURRENT_BINARY_DIR}/lyx2lyx_version.py)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/lyx2lyx_version.py DESTINATION ${DATA_SUBDIR}lyx2lyx)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/lyx2lyx_version.py DESTINATION ${LYX_DATA_SUBDIR}lyx2lyx)
if (UNIX)
set(_project "lyx2lyx")
include(../PyCompile)
endif()
install(PROGRAMS ${TOP_SRC_DIR}/lib/lyx2lyx/lyx2lyx DESTINATION ${DATA_SUBDIR}lyx2lyx)
install(PROGRAMS ${TOP_SRC_DIR}/lib/lyx2lyx/lyx2lyx DESTINATION ${LYX_DATA_SUBDIR}lyx2lyx)

View File

@ -26,7 +26,7 @@ endforeach(_mn)
ADD_CUSTOM_TARGET(man ALL DEPENDS ${_manuals})
install(FILES ${_manuals} DESTINATION ${DATA_SUBDIR}man/man1)
install(FILES ${_manuals} DESTINATION ${LYX_DATA_SUBDIR}man/man1)
# ADD_MANUALS("lyx")

View File

@ -38,7 +38,7 @@ macro(add_gettext_python _par _dir)
ADD_CUSTOM_COMMAND(
OUTPUT "${_dst}"
PRE_BUILD
COMMAND ${_PYTHON_EXECUTABLE}
COMMAND ${LYX_PYTHON_EXECUTABLE}
ARGS "${TOP_SRC_DIR}/po/lyx_pot.py" -b "${TOP_SRC_DIR}" -o "${_dst}" -t ${_par1} "--src_file=${_src_files}"
DEPENDS ${_sources} ${_src_files}
)
@ -64,7 +64,7 @@ FIND_PROGRAM(GETTEXT_MSGUNIQ_EXECUTABLE msguniq)
ADD_CUSTOM_COMMAND(
OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/${_lyxname}.cat.pot"
COMMAND ${_PYTHON_EXECUTABLE}
COMMAND ${LYX_PYTHON_EXECUTABLE}
ARGS "${CMAKE_SOURCE_DIR}/po/cat.py" ${_py_sources} > "${CMAKE_CURRENT_BINARY_DIR}/${_lyxname}.cat.pot"
DEPENDS ${_py_sources}
)