diff --git a/code/CMakeLists.txt b/code/CMakeLists.txt index 926f66e35..07bd52eba 100644 --- a/code/CMakeLists.txt +++ b/code/CMakeLists.txt @@ -48,9 +48,6 @@ SET(NL_VERSION_MINOR 8) SET(NL_VERSION_PATCH 0) SET(NL_VERSION "${NL_VERSION_MAJOR}.${NL_VERSION_MINOR}.${NL_VERSION_PATCH}") -NL_SETUP_BUILD() -NL_SETUP_BUILD_FLAGS() - #----------------------------------------------------------------------------- # Redirect output files SET(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin) @@ -87,6 +84,9 @@ RYZOM_SETUP_PREFIX_PATHS() NL_CONFIGURE_CHECKS() +NL_SETUP_BUILD() +NL_SETUP_BUILD_FLAGS() + #----------------------------------------------------------------------------- #Platform specifics @@ -230,7 +230,7 @@ IF(WIN32) "${QT_LIBRARY_DIR}/../bin/QtGuid4.dll" "${QT_LIBRARY_DIR}/../bin/QtXmld4.dll" "${QT_LIBRARY_DIR}/../bin/QtCored4.dll" - DESTINATION bin) + DESTINATION ${NL_BIN_PREFIX}) ENDIF(WITH_QT) ELSE(NOT CMAKE_BUILD_TYPE STREQUAL "Release") IF(WITH_QT) @@ -239,18 +239,18 @@ IF(WIN32) "${QT_LIBRARY_DIR}/../bin/QtGui4.dll" "${QT_LIBRARY_DIR}/../bin/QtXml4.dll" "${QT_LIBRARY_DIR}/../bin/QtCore4.dll" - DESTINATION bin) + DESTINATION ${NL_BIN_PREFIX}) ENDIF(WITH_QT) ENDIF(NOT CMAKE_BUILD_TYPE STREQUAL "Release") # Install CEGUI and its dependencies. IF(WITH_NEL_CEGUI) - INSTALL(FILES "${CEGUI_LIB_DIR}/CEGUIBase.dll" DESTINATION bin) - INSTALL(FILES "${CEGUI_LIB_DIR}/CEGUIDevilImageCodec.dll" DESTINATION bin) - INSTALL(FILES "${CEGUI_LIB_DIR}/CEGUIExpatParser.dll" DESTINATION bin) - INSTALL(FILES "${CEGUI_LIB_DIR}/CEGUIFalagardWRBase.dll" DESTINATION bin) - INSTALL(FILES "${CEGUI_LIB_DIR}/Devil.dll" DESTINATION bin) - INSTALL(FILES "${CEGUI_LIB_DIR}/ILU.dll" DESTINATION bin) + INSTALL(FILES "${CEGUI_LIB_DIR}/CEGUIBase.dll" DESTINATION ${NL_BIN_PREFIX}) + INSTALL(FILES "${CEGUI_LIB_DIR}/CEGUIDevilImageCodec.dll" DESTINATION ${NL_BIN_PREFIX}) + INSTALL(FILES "${CEGUI_LIB_DIR}/CEGUIExpatParser.dll" DESTINATION ${NL_BIN_PREFIX}) + INSTALL(FILES "${CEGUI_LIB_DIR}/CEGUIFalagardWRBase.dll" DESTINATION ${NL_BIN_PREFIX}) + INSTALL(FILES "${CEGUI_LIB_DIR}/Devil.dll" DESTINATION ${NL_BIN_PREFIX}) + INSTALL(FILES "${CEGUI_LIB_DIR}/ILU.dll" DESTINATION ${NL_BIN_PREFIX}) ENDIF(WITH_NEL_CEGUI) # Only the tools require MFC. diff --git a/code/CMakeModules/FindSquish.cmake b/code/CMakeModules/FindSquish.cmake index 04f657485..ad0f7ce80 100644 --- a/code/CMakeModules/FindSquish.cmake +++ b/code/CMakeModules/FindSquish.cmake @@ -12,7 +12,7 @@ IF(SQUISH_LIBRARIES AND SQUISH_INCLUDE_DIR) SET(SQUISH_FIND_QUIETLY TRUE) ENDIF(SQUISH_LIBRARIES AND SQUISH_INCLUDE_DIR) -FIND_PATH(SQUISH_INCLUDE_DIR +FIND_PATH(SQUISH_INCLUDE_DIR squish.h PATHS /usr/local/include @@ -67,6 +67,11 @@ IF(SQUISH_FOUND) IF(NOT SQUISH_FIND_QUIETLY) MESSAGE(STATUS "Found Squish: ${SQUISH_LIBRARIES}") ENDIF(NOT SQUISH_FIND_QUIETLY) + FILE(STRINGS ${SQUISH_INCLUDE_DIR}/squish.h METRIC REGEX "metric = 0") + IF(METRIC) + SET(SQUISH_COMPRESS_HAS_METRIC ON) + SET(SQUISH_DEFINITIONS -DSQUISH_COMPRESS_HAS_METRIC) + ENDIF(METRIC) ELSE(SQUISH_FOUND) IF(NOT SQUISH_FIND_QUIETLY) MESSAGE(STATUS "Warning: Unable to find Squish!") diff --git a/code/CMakeModules/nel.cmake b/code/CMakeModules/nel.cmake index b3db9ef7a..be7032905 100644 --- a/code/CMakeModules/nel.cmake +++ b/code/CMakeModules/nel.cmake @@ -30,21 +30,28 @@ MACRO(NL_GEN_REVISION_H) ADD_DEFINITIONS(-DHAVE_REVISION_H) SET(HAVE_REVISION_H ON) - # a custom target that is always built - ADD_CUSTOM_TARGET(revision ALL - DEPENDS ${CMAKE_BINARY_DIR}/revision.h) - - # creates revision.h using cmake script - ADD_CUSTOM_COMMAND(OUTPUT ${CMAKE_BINARY_DIR}/revision.h - COMMAND ${CMAKE_COMMAND} - -DSOURCE_DIR=${CMAKE_SOURCE_DIR} - -DROOT_DIR=${CMAKE_SOURCE_DIR}/.. - -P ${CMAKE_SOURCE_DIR}/CMakeModules/GetRevision.cmake) - - # revision.h is a generated file - SET_SOURCE_FILES_PROPERTIES(${CMAKE_BINARY_DIR}/revision.h - PROPERTIES GENERATED TRUE - HEADER_FILE_ONLY TRUE) + # if already generated + IF(EXISTS ${CMAKE_SOURCE_DIR}/revision.h) + # copy it + MESSAGE(STATUS "Copying provided revision.h...") + FILE(COPY ${CMAKE_SOURCE_DIR}/revision.h DESTINATION ${CMAKE_BINARY_DIR}) + ELSE(EXISTS ${CMAKE_SOURCE_DIR}/revision.h) + # a custom target that is always built + ADD_CUSTOM_TARGET(revision ALL + DEPENDS ${CMAKE_BINARY_DIR}/revision.h) + + # creates revision.h using cmake script + ADD_CUSTOM_COMMAND(OUTPUT ${CMAKE_BINARY_DIR}/revision.h + COMMAND ${CMAKE_COMMAND} + -DSOURCE_DIR=${CMAKE_SOURCE_DIR} + -DROOT_DIR=${CMAKE_SOURCE_DIR}/.. + -P ${CMAKE_SOURCE_DIR}/CMakeModules/GetRevision.cmake) + + # revision.h is a generated file + SET_SOURCE_FILES_PROPERTIES(${CMAKE_BINARY_DIR}/revision.h + PROPERTIES GENERATED TRUE + HEADER_FILE_ONLY TRUE) + ENDIF(EXISTS ${CMAKE_SOURCE_DIR}/revision.h) ENDIF(EXISTS ${CMAKE_SOURCE_DIR}/revision.h.in) ENDMACRO(NL_GEN_REVISION_H) @@ -419,6 +426,18 @@ MACRO(NL_SETUP_BUILD) MESSAGE(STATUS "Compiling on ${HOST_CPU} for ${TARGET_CPU}") ENDIF("${HOST_CPU}" STREQUAL "${TARGET_CPU}") + # Use values from environment variables + SET(PLATFORM_CFLAGS "$ENV{CFLAGS} ${PLATFORM_CFLAGS}") + SET(PLATFORM_LINKFLAGS "$ENV{LDFLAGS} ${PLATFORM_LINKFLAGS}") + + # Remove -g and -O flag because we are managing them ourself + STRING(REPLACE "-g" "" PLATFORM_CFLAGS ${PLATFORM_CFLAGS}) + STRING(REGEX REPLACE "-O[0-9s]" "" PLATFORM_CFLAGS ${PLATFORM_CFLAGS}) + + # Strip spaces + STRING(STRIP ${PLATFORM_CFLAGS} PLATFORM_CFLAGS) + STRING(STRIP ${PLATFORM_LINKFLAGS} PLATFORM_LINKFLAGS) + IF(TARGET_CPU STREQUAL "x86_64") SET(TARGET_X64 1) SET(PLATFORM_CFLAGS "${PLATFORM_CFLAGS} -DHAVE_X86_64") @@ -469,9 +488,6 @@ MACRO(NL_SETUP_BUILD) SET(PLATFORM_CFLAGS "${PLATFORM_CFLAGS} /D_CRT_SECURE_NO_WARNINGS /D_CRT_NONSTDC_NO_WARNINGS /DWIN32 /D_WINDOWS /W3 /Zm1000 /MP /Gy-") - # Common link flags - SET(PLATFORM_LINKFLAGS "") - IF(TARGET_X64) # Fix a bug with Intellisense SET(PLATFORM_CFLAGS "${PLATFORM_CFLAGS} /D_WIN64") @@ -519,7 +535,7 @@ MACRO(NL_SETUP_BUILD) ENDIF(HOST_CPU STREQUAL "x86" AND TARGET_CPU STREQUAL "x86_64") ENDIF(APPLE) - SET(PLATFORM_CFLAGS "${PLATFORM_CFLAGS} -D_REENTRANT -pipe -ftemplate-depth-48 -Wall -W -Wpointer-arith -Wsign-compare -Wno-deprecated-declarations -Wno-multichar -Wno-unused -fno-strict-aliasing") + SET(PLATFORM_CFLAGS "${PLATFORM_CFLAGS} -D_REENTRANT -pipe -Wall -W -Wpointer-arith -Wsign-compare -Wno-deprecated-declarations -Wno-multichar -Wno-unused -fno-strict-aliasing") IF(NOT ${CMAKE_CXX_COMPILER_ID} STREQUAL "Clang") SET(PLATFORM_CFLAGS "${PLATFORM_CFLAGS} -ansi") @@ -534,7 +550,7 @@ MACRO(NL_SETUP_BUILD) ENDIF(APPLE) IF(APPLE AND XCODE) - SET(CMAKE_OSX_SYSROOT "macosx" CACHE PATH "" FORCE) +# SET(CMAKE_OSX_SYSROOT "macosx" CACHE PATH "" FORCE) ELSEIF(APPLE AND NOT XCODE) IF(NOT CMAKE_OSX_DEPLOYMENT_TARGET) SET(CMAKE_OSX_DEPLOYMENT_TARGET "10.6") @@ -573,7 +589,7 @@ MACRO(NL_SETUP_BUILD) SET(PLATFORM_CFLAGS "-fPIC ${PLATFORM_CFLAGS}") ENDIF(TARGET_X64 AND WITH_STATIC AND NOT WITH_STATIC_DRIVERS) - SET(PLATFORM_CXXFLAGS ${PLATFORM_CFLAGS}) + SET(PLATFORM_CXXFLAGS "${PLATFORM_CFLAGS} -ftemplate-depth-48") IF(NOT APPLE) SET(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Wl,--no-undefined -Wl,--as-needed") @@ -613,125 +629,146 @@ MACRO(NL_SETUP_BUILD_FLAGS) SET(CMAKE_SHARED_LINKER_FLAGS_RELEASE "${PLATFORM_LINKFLAGS} ${NL_RELEASE_LINKFLAGS}" CACHE STRING "" FORCE) ENDMACRO(NL_SETUP_BUILD_FLAGS) +# Macro to create x_ABSOLUTE_PREFIX from x_PREFIX +MACRO(NL_MAKE_ABSOLUTE_PREFIX NAME_RELATIVE NAME_ABSOLUTE) + IF(IS_ABSOLUTE "${${NAME_RELATIVE}}") + SET(${NAME_ABSOLUTE} ${${NAME_RELATIVE}}) + ELSE(IS_ABSOLUTE "${${{NAME_RELATIVE}}") + IF(WIN32) + SET(${NAME_ABSOLUTE} ${${NAME_RELATIVE}}) + ELSE(WIN32) + SET(${NAME_ABSOLUTE} ${CMAKE_INSTALL_PREFIX}/${${NAME_RELATIVE}}) + ENDIF(WIN32) + ENDIF(IS_ABSOLUTE "${${NAME_RELATIVE}}") +ENDMACRO(NL_MAKE_ABSOLUTE_PREFIX) + MACRO(NL_SETUP_PREFIX_PATHS) ## Allow override of install_prefix/etc path. IF(NOT NL_ETC_PREFIX) IF(WIN32) - SET(NL_ETC_PREFIX "../etc/nel" CACHE PATH "Installation path for configurations") + SET(NL_ETC_PREFIX "." CACHE PATH "Installation path for configurations") ELSE(WIN32) - SET(NL_ETC_PREFIX "${CMAKE_INSTALL_PREFIX}/etc/nel" CACHE PATH "Installation path for configurations") + SET(NL_ETC_PREFIX "etc/nel" CACHE PATH "Installation path for configurations") ENDIF(WIN32) ENDIF(NOT NL_ETC_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(NL_ETC_PREFIX NL_ETC_ABSOLUTE_PREFIX) ## Allow override of install_prefix/share path. IF(NOT NL_SHARE_PREFIX) IF(WIN32) - SET(NL_SHARE_PREFIX "../share/nel" CACHE PATH "Installation path for data.") + SET(NL_SHARE_PREFIX "." CACHE PATH "Installation path for data.") ELSE(WIN32) - SET(NL_SHARE_PREFIX "${CMAKE_INSTALL_PREFIX}/share/nel" CACHE PATH "Installation path for data.") + SET(NL_SHARE_PREFIX "share/nel" CACHE PATH "Installation path for data.") ENDIF(WIN32) ENDIF(NOT NL_SHARE_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(NL_SHARE_PREFIX NL_SHARE_ABSOLUTE_PREFIX) ## Allow override of install_prefix/sbin path. IF(NOT NL_SBIN_PREFIX) IF(WIN32) - SET(NL_SBIN_PREFIX "../sbin" CACHE PATH "Installation path for admin tools and services.") + SET(NL_SBIN_PREFIX "." CACHE PATH "Installation path for admin tools and services.") ELSE(WIN32) - SET(NL_SBIN_PREFIX "${CMAKE_INSTALL_PREFIX}/sbin" CACHE PATH "Installation path for admin tools and services.") + SET(NL_SBIN_PREFIX "sbin" CACHE PATH "Installation path for admin tools and services.") ENDIF(WIN32) ENDIF(NOT NL_SBIN_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(NL_SBIN_PREFIX NL_SBIN_ABSOLUTE_PREFIX) ## Allow override of install_prefix/bin path. IF(NOT NL_BIN_PREFIX) IF(WIN32) - SET(NL_BIN_PREFIX "../bin" CACHE PATH "Installation path for tools and applications.") + SET(NL_BIN_PREFIX "." CACHE PATH "Installation path for tools and applications.") ELSE(WIN32) - SET(NL_BIN_PREFIX "${CMAKE_INSTALL_PREFIX}/bin" CACHE PATH "Installation path for tools and applications.") + SET(NL_BIN_PREFIX "bin" CACHE PATH "Installation path for tools and applications.") ENDIF(WIN32) ENDIF(NOT NL_BIN_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(NL_BIN_PREFIX NL_BIN_ABSOLUTE_PREFIX) ## Allow override of install_prefix/lib path. IF(NOT NL_LIB_PREFIX) - IF(WIN32) - SET(NL_LIB_PREFIX "../lib" CACHE PATH "Installation path for libraries.") - ELSE(WIN32) - IF(CMAKE_LIBRARY_ARCHITECTURE) - SET(NL_LIB_PREFIX "${CMAKE_INSTALL_PREFIX}/lib/${CMAKE_LIBRARY_ARCHITECTURE}" CACHE PATH "Installation path for libraries.") - ELSE(CMAKE_LIBRARY_ARCHITECTURE) - SET(NL_LIB_PREFIX "${CMAKE_INSTALL_PREFIX}/lib" CACHE PATH "Installation path for libraries.") - ENDIF(CMAKE_LIBRARY_ARCHITECTURE) - ENDIF(WIN32) + IF(CMAKE_LIBRARY_ARCHITECTURE) + SET(NL_LIB_PREFIX "lib/${CMAKE_LIBRARY_ARCHITECTURE}" CACHE PATH "Installation path for libraries.") + ELSE(CMAKE_LIBRARY_ARCHITECTURE) + SET(NL_LIB_PREFIX "lib" CACHE PATH "Installation path for libraries.") + ENDIF(CMAKE_LIBRARY_ARCHITECTURE) ENDIF(NOT NL_LIB_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(NL_LIB_PREFIX NL_LIB_ABSOLUTE_PREFIX) ## Allow override of install_prefix/lib path. IF(NOT NL_DRIVER_PREFIX) IF(WIN32) - SET(NL_DRIVER_PREFIX "../lib" CACHE PATH "Installation path for drivers.") + SET(NL_DRIVER_PREFIX "." CACHE PATH "Installation path for drivers.") ELSE(WIN32) IF(CMAKE_LIBRARY_ARCHITECTURE) - SET(NL_DRIVER_PREFIX "${CMAKE_INSTALL_PREFIX}/lib/${CMAKE_LIBRARY_ARCHITECTURE}/nel" CACHE PATH "Installation path for drivers.") + SET(NL_DRIVER_PREFIX "lib/${CMAKE_LIBRARY_ARCHITECTURE}/nel" CACHE PATH "Installation path for drivers.") ELSE(CMAKE_LIBRARY_ARCHITECTURE) - SET(NL_DRIVER_PREFIX "${CMAKE_INSTALL_PREFIX}/lib/nel" CACHE PATH "Installation path for drivers.") + SET(NL_DRIVER_PREFIX "lib/nel" CACHE PATH "Installation path for drivers.") ENDIF(CMAKE_LIBRARY_ARCHITECTURE) ENDIF(WIN32) ENDIF(NOT NL_DRIVER_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(NL_DRIVER_PREFIX NL_DRIVER_ABSOLUTE_PREFIX) ENDMACRO(NL_SETUP_PREFIX_PATHS) MACRO(RYZOM_SETUP_PREFIX_PATHS) - ## Allow override of install_prefix path. - IF(NOT RYZOM_PREFIX) - IF(WIN32) - SET(RYZOM_PREFIX "." CACHE PATH "Installation path") - ELSE(WIN32) - SET(RYZOM_PREFIX "${CMAKE_INSTALL_PREFIX}" CACHE PATH "Installation path") - ENDIF(WIN32) - ENDIF(NOT RYZOM_PREFIX) - ## Allow override of install_prefix/etc path. IF(NOT RYZOM_ETC_PREFIX) IF(WIN32) SET(RYZOM_ETC_PREFIX "." CACHE PATH "Installation path for configurations") ELSE(WIN32) - SET(RYZOM_ETC_PREFIX "${RYZOM_PREFIX}/etc/ryzom" CACHE PATH "Installation path for configurations") + SET(RYZOM_ETC_PREFIX "etc/ryzom" CACHE PATH "Installation path for configurations") ENDIF(WIN32) ENDIF(NOT RYZOM_ETC_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(RYZOM_ETC_PREFIX RYZOM_ETC_ABSOLUTE_PREFIX) ## Allow override of install_prefix/share path. IF(NOT RYZOM_SHARE_PREFIX) IF(WIN32) SET(RYZOM_SHARE_PREFIX "." CACHE PATH "Installation path for data.") ELSE(WIN32) - SET(RYZOM_SHARE_PREFIX "${RYZOM_PREFIX}/share/ryzom" CACHE PATH "Installation path for data.") + SET(RYZOM_SHARE_PREFIX "share/ryzom" CACHE PATH "Installation path for data.") ENDIF(WIN32) ENDIF(NOT RYZOM_SHARE_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(RYZOM_SHARE_PREFIX RYZOM_SHARE_ABSOLUTE_PREFIX) ## Allow override of install_prefix/sbin path. IF(NOT RYZOM_SBIN_PREFIX) IF(WIN32) SET(RYZOM_SBIN_PREFIX "." CACHE PATH "Installation path for admin tools and services.") ELSE(WIN32) - SET(RYZOM_SBIN_PREFIX "${RYZOM_PREFIX}/sbin" CACHE PATH "Installation path for admin tools and services.") + SET(RYZOM_SBIN_PREFIX "sbin" CACHE PATH "Installation path for admin tools and services.") ENDIF(WIN32) ENDIF(NOT RYZOM_SBIN_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(RYZOM_SBIN_PREFIX RYZOM_SBIN_ABSOLUTE_PREFIX) ## Allow override of install_prefix/bin path. IF(NOT RYZOM_BIN_PREFIX) IF(WIN32) SET(RYZOM_BIN_PREFIX "." CACHE PATH "Installation path for tools and applications.") ELSE(WIN32) - SET(RYZOM_BIN_PREFIX "${RYZOM_PREFIX}/bin" CACHE PATH "Installation path for tools.") + SET(RYZOM_BIN_PREFIX "bin" CACHE PATH "Installation path for tools.") ENDIF(WIN32) ENDIF(NOT RYZOM_BIN_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(RYZOM_BIN_PREFIX RYZOM_BIN_ABSOLUTE_PREFIX) + + ## Allow override of install_prefix/lib path. + IF(NOT RYZOM_LIB_PREFIX) + IF(CMAKE_LIBRARY_ARCHITECTURE) + SET(RYZOM_LIB_PREFIX "lib/${CMAKE_LIBRARY_ARCHITECTURE}" CACHE PATH "Installation path for libraries.") + ELSE(CMAKE_LIBRARY_ARCHITECTURE) + SET(RYZOM_LIB_PREFIX "lib" CACHE PATH "Installation path for libraries.") + ENDIF(CMAKE_LIBRARY_ARCHITECTURE) + ENDIF(NOT RYZOM_LIB_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(RYZOM_LIB_PREFIX RYZOM_LIB_ABSOLUTE_PREFIX) ## Allow override of install_prefix/games path. IF(NOT RYZOM_GAMES_PREFIX) IF(WIN32) SET(RYZOM_GAMES_PREFIX "." CACHE PATH "Installation path for tools and applications.") ELSE(WIN32) - SET(RYZOM_GAMES_PREFIX "${RYZOM_PREFIX}/games" CACHE PATH "Installation path for client.") + SET(RYZOM_GAMES_PREFIX "games" CACHE PATH "Installation path for client.") ENDIF(WIN32) ENDIF(NOT RYZOM_GAMES_PREFIX) + NL_MAKE_ABSOLUTE_PREFIX(RYZOM_GAMES_PREFIX RYZOM_GAMES_ABSOLUTE_PREFIX) ENDMACRO(RYZOM_SETUP_PREFIX_PATHS) diff --git a/code/config.h.cmake b/code/config.h.cmake index 2f2ff8095..d3c9f701d 100644 --- a/code/config.h.cmake +++ b/code/config.h.cmake @@ -43,15 +43,14 @@ #cmakedefine NL_DSOUND_AVAILABLE ${NL_DSOUND_AVAILABLE} #cmakedefine NL_XAUDIO2_AVAILABLE ${NL_XAUDIO2_AVAILABLE} -#cmakedefine NL_BIN_PREFIX "${NL_BIN_PREFIX}" -#cmakedefine NL_ETC_PREFIX "${NL_ETC_PREFIX}" -#cmakedefine NL_SHARE_PREFIX "${NL_SHARE_PREFIX}" -#cmakedefine NL_LIB_PREFIX "${NL_LIB_PREFIX}" -#cmakedefine NL_DRIVER_PREFIX "${NL_DRIVER_PREFIX}" +#cmakedefine NL_BIN_PREFIX "${NL_BIN_ABSOLUTE_PREFIX}" +#cmakedefine NL_ETC_PREFIX "${NL_ETC_ABSOLUTE_PREFIX}" +#cmakedefine NL_SHARE_PREFIX "${NL_SHARE_ABSOLUTE_PREFIX}" +#cmakedefine NL_LIB_PREFIX "${NL_LIB_ABSOLUTE_PREFIX}" +#cmakedefine NL_DRIVER_PREFIX "${NL_DRIVER_ABSOLUTE_PREFIX}" -#cmakedefine RYZOM_PREFIX "${RYZOM_PREFIX}" -#cmakedefine RYZOM_BIN_PREFIX "${RYZOM_BIN_PREFIX}" -#cmakedefine RYZOM_ETC_PREFIX "${RYZOM_ETC_PREFIX}" -#cmakedefine RYZOM_SHARE_PREFIX "${RYZOM_SHARE_PREFIX}" +#cmakedefine RYZOM_BIN_PREFIX "${RYZOM_BIN_ABSOLUTE_PREFIX}" +#cmakedefine RYZOM_ETC_PREFIX "${RYZOM_ETC_ABSOLUTE_PREFIX}" +#cmakedefine RYZOM_SHARE_PREFIX "${RYZOM_SHARE_ABSOLUTE_PREFIX}" #endif // CONFIG_H diff --git a/code/nel/CMakeLists.txt b/code/nel/CMakeLists.txt index 9cb8f42f1..1929135b4 100644 --- a/code/nel/CMakeLists.txt +++ b/code/nel/CMakeLists.txt @@ -44,8 +44,8 @@ ENDIF(WITH_GTK) IF(WITH_INSTALL_LIBRARIES) IF(UNIX) SET(prefix ${CMAKE_INSTALL_PREFIX}) - SET(exec_prefix ${CMAKE_INSTALL_PREFIX}/bin) - SET(libdir ${CMAKE_INSTALL_PREFIX}/lib) + SET(exec_prefix ${NL_BIN_ABSOLUTE_PREFIX}) + SET(libdir ${NL_LIB_ABSOLUTE_PREFIX}) SET(includedir ${CMAKE_INSTALL_PREFIX}/include) SET(enable_ligo ${WITH_LIGO}) SET(enable_logic ${WITH_LOGIC}) @@ -56,7 +56,7 @@ IF(WITH_INSTALL_LIBRARIES) SET(enable_sound ${WITH_SOUND}) CONFIGURE_FILE(nel-config.in ${CMAKE_CURRENT_BINARY_DIR}/nel-config) - INSTALL(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/nel-config DESTINATION bin) + INSTALL(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/nel-config DESTINATION ${NL_BIN_PREFIX}) ENDIF(UNIX) ADD_SUBDIRECTORY(include) diff --git a/code/nel/include/nel/misc/eval_num_expr.h b/code/nel/include/nel/misc/eval_num_expr.h index 18cb14725..8551e49df 100644 --- a/code/nel/include/nel/misc/eval_num_expr.h +++ b/code/nel/include/nel/misc/eval_num_expr.h @@ -241,7 +241,7 @@ private: LogicalXor, // ^^ OperatorCount, // NotOperator, // This is not an operator - ExtOperator, // This is a 2 charcters operator + ExtOperator, // This is a 2 characters operator }; // Functions diff --git a/code/nel/include/nel/net/message_recorder.h b/code/nel/include/nel/net/message_recorder.h index a7b5ac51f..5874aca4c 100644 --- a/code/nel/include/nel/net/message_recorder.h +++ b/code/nel/include/nel/net/message_recorder.h @@ -79,7 +79,7 @@ struct TMessageRecord stream.serial( s_event ); uint32 sockId; stream.serialHex( sockId ); - SockId = (NLNET::TSockId)sockId; + SockId = (NLNET::TSockId)(size_t)sockId; len = Message.length(); stream.serial( len ); stream.serialBuffer( const_cast(Message.buffer()), len ); // assumes the message contains plain text diff --git a/code/nel/samples/3d/cegui/CMakeLists.txt b/code/nel/samples/3d/cegui/CMakeLists.txt index c1da6eafe..3a8650a19 100644 --- a/code/nel/samples/3d/cegui/CMakeLists.txt +++ b/code/nel/samples/3d/cegui/CMakeLists.txt @@ -2,7 +2,7 @@ FILE(GLOB SRC *.cpp *.h) ADD_EXECUTABLE(nl_sample_cegui WIN32 ${SRC}) -ADD_DEFINITIONS(-DCEGUI_DATA_DIR="\\"${NL_SHARE_PREFIX}/nl_sample_cegui/datafiles/\\"") +ADD_DEFINITIONS(-DCEGUI_DATA_DIR="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_cegui/datafiles/\\"") INCLUDE_DIRECTORIES(${CEGUI_INCLUDE_DIRS}) @@ -10,9 +10,9 @@ TARGET_LINK_LIBRARIES(nl_sample_cegui ${CEGUI_LIBRARY} nelmisc nel3d) NL_DEFAULT_PROPS(nl_sample_cegui "NeL, Samples, 3D: NeL CEGUI Demo") NL_ADD_RUNTIME_FLAGS(nl_sample_cegui) -INSTALL(TARGETS nl_sample_cegui RUNTIME DESTINATION bin COMPONENT samples3d) +INSTALL(TARGETS nl_sample_cegui RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samples3d) INSTALL(DIRECTORY datafiles/ - DESTINATION share/nel/nl_sample_cegui/datafiles + DESTINATION ${NL_SHARE_PREFIX}/nl_sample_cegui/datafiles COMPONENT samples3d PATTERN "CVS" EXCLUDE PATTERN ".svn" EXCLUDE diff --git a/code/nel/samples/3d/cluster_viewer/CMakeLists.txt b/code/nel/samples/3d/cluster_viewer/CMakeLists.txt index 4d1bb0d68..ad8bdb98d 100644 --- a/code/nel/samples/3d/cluster_viewer/CMakeLists.txt +++ b/code/nel/samples/3d/cluster_viewer/CMakeLists.txt @@ -2,34 +2,34 @@ FILE(GLOB SRC *.cpp) ADD_EXECUTABLE(nl_sample_clusterview WIN32 ${SRC}) -ADD_DEFINITIONS(-DCV_DIR="\\"${NL_SHARE_PREFIX}/nl_sample_clusterview/\\"") +ADD_DEFINITIONS(-DCV_DIR="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_clusterview/\\"") TARGET_LINK_LIBRARIES(nl_sample_clusterview nelmisc nel3d) NL_ADD_RUNTIME_FLAGS(nl_sample_clusterview) NL_DEFAULT_PROPS(nl_sample_clusterview "NeL, Samples, 3D: Cluster Viewer") -INSTALL(TARGETS nl_sample_clusterview RUNTIME DESTINATION bin COMPONENT samples3d) -INSTALL(FILES main.cvs readme.txt DESTINATION share/nel/nl_sample_clusterview COMPONENT samples3d) +INSTALL(TARGETS nl_sample_clusterview RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samples3d) +INSTALL(FILES main.cvs readme.txt DESTINATION ${NL_SHARE_PREFIX}/nl_sample_clusterview COMPONENT samples3d) INSTALL(DIRECTORY groups/ - DESTINATION share/nel/nl_sample_clusterview/groups + DESTINATION ${NL_SHARE_PREFIX}/nl_sample_clusterview/groups COMPONENT samples3d PATTERN "CVS" EXCLUDE PATTERN ".svn" EXCLUDE PATTERN "Makefile*" EXCLUDE) INSTALL(DIRECTORY fonts/ - DESTINATION share/nel/nl_sample_clusterview/fonts + DESTINATION ${NL_SHARE_PREFIX}/nl_sample_clusterview/fonts COMPONENT samples3d PATTERN "CVS" EXCLUDE PATTERN ".svn" EXCLUDE PATTERN "Makefile*" EXCLUDE) INSTALL(DIRECTORY max/ - DESTINATION share/nel/nl_sample_clusterview/max + DESTINATION ${NL_SHARE_PREFIX}/nl_sample_clusterview/max COMPONENT samples3d PATTERN "CVS" EXCLUDE PATTERN ".svn" EXCLUDE PATTERN "Makefile*" EXCLUDE) INSTALL(DIRECTORY shapes/ - DESTINATION share/nel/nl_sample_clusterview/shapes + DESTINATION ${NL_SHARE_PREFIX}/nl_sample_clusterview/shapes COMPONENT samples3d PATTERN "CVS" EXCLUDE PATTERN ".svn" EXCLUDE diff --git a/code/nel/samples/3d/font/CMakeLists.txt b/code/nel/samples/3d/font/CMakeLists.txt index d3024fe0b..a944ef643 100644 --- a/code/nel/samples/3d/font/CMakeLists.txt +++ b/code/nel/samples/3d/font/CMakeLists.txt @@ -2,11 +2,11 @@ FILE(GLOB SRC *.cpp) ADD_EXECUTABLE(nl_sample_font WIN32 ${SRC}) -ADD_DEFINITIONS(-DFONT_DIR="\\"${NL_SHARE_PREFIX}/nl_sample_font/\\"") +ADD_DEFINITIONS(-DFONT_DIR="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_font/\\"") TARGET_LINK_LIBRARIES(nl_sample_font nelmisc nel3d) NL_DEFAULT_PROPS(nl_sample_font "NeL, Samples, 3D: Font") NL_ADD_RUNTIME_FLAGS(nl_sample_font) -INSTALL(TARGETS nl_sample_font RUNTIME DESTINATION bin COMPONENT samples3d) -INSTALL(FILES beteckna.ttf DESTINATION share/nel/nl_sample_font COMPONENT samples3d) +INSTALL(TARGETS nl_sample_font RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samples3d) +INSTALL(FILES beteckna.ttf DESTINATION ${NL_SHARE_PREFIX}/nl_sample_font COMPONENT samples3d) diff --git a/code/nel/samples/3d/qtnel/CMakeLists.txt b/code/nel/samples/3d/qtnel/CMakeLists.txt index 5b996a33e..1730cd4b3 100644 --- a/code/nel/samples/3d/qtnel/CMakeLists.txt +++ b/code/nel/samples/3d/qtnel/CMakeLists.txt @@ -27,5 +27,5 @@ NL_ADD_RUNTIME_FLAGS(qtnel) ADD_DEFINITIONS(${QT_DEFINITIONS}) -INSTALL(TARGETS qtnel RUNTIME DESTINATION bin COMPONENT samples3d) +INSTALL(TARGETS qtnel RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samples3d) diff --git a/code/nel/samples/3d/shape_viewer/CMakeLists.txt b/code/nel/samples/3d/shape_viewer/CMakeLists.txt index 57f2ddd5a..9262a7cd7 100644 --- a/code/nel/samples/3d/shape_viewer/CMakeLists.txt +++ b/code/nel/samples/3d/shape_viewer/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(nl_sample_shapeview nelmisc nel3d) NL_DEFAULT_PROPS(nl_sample_shapeview "NeL, Samples, 3D: Shape Viewer") NL_ADD_RUNTIME_FLAGS(nl_sample_shapeview) -INSTALL(TARGETS nl_sample_shapeview RUNTIME DESTINATION bin COMPONENT samples3d) +INSTALL(TARGETS nl_sample_shapeview RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samples3d) diff --git a/code/nel/samples/georges/CMakeLists.txt b/code/nel/samples/georges/CMakeLists.txt index 7740a8d14..ed83e9ce3 100644 --- a/code/nel/samples/georges/CMakeLists.txt +++ b/code/nel/samples/georges/CMakeLists.txt @@ -2,12 +2,12 @@ FILE(GLOB SRC *.cpp) ADD_EXECUTABLE(nl_sample_georges ${SRC}) -ADD_DEFINITIONS(-DGF_DIR="\\"${NL_SHARE_PREFIX}/nl_sample_georges/\\"") +ADD_DEFINITIONS(-DGF_DIR="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_georges/\\"") TARGET_LINK_LIBRARIES(nl_sample_georges nelgeorges nelmisc) NL_DEFAULT_PROPS(nl_sample_georges "NeL, Samples: Georges") NL_ADD_RUNTIME_FLAGS(nl_sample_georges) -INSTALL(TARGETS nl_sample_georges RUNTIME DESTINATION bin COMPONENT samplesgeorges) +INSTALL(TARGETS nl_sample_georges RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesgeorges) INSTALL(FILES boolean.typ coolfilesinfo.dfn default.sample_config int.typ positiondata.dfn sample_config.dfn string.typ sheet_id.bin - DESTINATION share/nel/nl_sample_georges/ COMPONENT samplesgeorges) + DESTINATION ${NL_SHARE_PREFIX}/nl_sample_georges/ COMPONENT samplesgeorges) diff --git a/code/nel/samples/misc/command/CMakeLists.txt b/code/nel/samples/misc/command/CMakeLists.txt index 5ffe1f42d..8069e8bd0 100644 --- a/code/nel/samples/misc/command/CMakeLists.txt +++ b/code/nel/samples/misc/command/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(nl_sample_command nelmisc) NL_DEFAULT_PROPS(nl_sample_command "NeL, Samples, Misc: Commands") NL_ADD_RUNTIME_FLAGS(nl_sample_command) -INSTALL(TARGETS nl_sample_command RUNTIME DESTINATION bin COMPONENT samplesmisc) +INSTALL(TARGETS nl_sample_command RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesmisc) diff --git a/code/nel/samples/misc/configfile/CMakeLists.txt b/code/nel/samples/misc/configfile/CMakeLists.txt index d826aafa0..3d29c082c 100644 --- a/code/nel/samples/misc/configfile/CMakeLists.txt +++ b/code/nel/samples/misc/configfile/CMakeLists.txt @@ -2,11 +2,11 @@ FILE(GLOB SRC *.cpp) ADD_EXECUTABLE(nl_sample_configfile ${SRC}) -ADD_DEFINITIONS(-DNL_SAMPLE_CFG="\\"${NL_SHARE_PREFIX}/nl_sample_configfile/\\"") +ADD_DEFINITIONS(-DNL_SAMPLE_CFG="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_configfile/\\"") TARGET_LINK_LIBRARIES(nl_sample_configfile nelmisc) NL_DEFAULT_PROPS(nl_sample_configfile "NeL, Samples, Misc: Config Files") NL_ADD_RUNTIME_FLAGS(nl_sample_configfile) -INSTALL(TARGETS nl_sample_configfile RUNTIME DESTINATION bin COMPONENT samplesmisc) -INSTALL(FILES simpletest.txt DESTINATION share/nel/nl_sample_configfile COMPONENT samplesmisc) +INSTALL(TARGETS nl_sample_configfile RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesmisc) +INSTALL(FILES simpletest.txt DESTINATION ${NL_SHARE_PREFIX}/nl_sample_configfile COMPONENT samplesmisc) diff --git a/code/nel/samples/misc/debug/CMakeLists.txt b/code/nel/samples/misc/debug/CMakeLists.txt index 16c3ae42b..c2cd617a3 100644 --- a/code/nel/samples/misc/debug/CMakeLists.txt +++ b/code/nel/samples/misc/debug/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(nl_sample_debug nelmisc) NL_DEFAULT_PROPS(nl_sample_debug "NeL, Samples, Misc: Debugging") NL_ADD_RUNTIME_FLAGS(nl_sample_debug) -INSTALL(TARGETS nl_sample_debug RUNTIME DESTINATION bin COMPONENT samplesmisc) +INSTALL(TARGETS nl_sample_debug RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesmisc) diff --git a/code/nel/samples/misc/i18n/CMakeLists.txt b/code/nel/samples/misc/i18n/CMakeLists.txt index f2787175e..5238b6180 100644 --- a/code/nel/samples/misc/i18n/CMakeLists.txt +++ b/code/nel/samples/misc/i18n/CMakeLists.txt @@ -2,11 +2,11 @@ FILE(GLOB SRC *.cpp) ADD_EXECUTABLE(nl_sample_i18n ${SRC}) -ADD_DEFINITIONS(-DNL_LANG_DATA="\\"${NL_SHARE_PREFIX}/nl_sample_i18n/\\"") +ADD_DEFINITIONS(-DNL_LANG_DATA="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_i18n/\\"") TARGET_LINK_LIBRARIES(nl_sample_i18n nelmisc) NL_DEFAULT_PROPS(nl_sample_i18n "NeL, Samples, Misc: I18N") NL_ADD_RUNTIME_FLAGS(nl_sample_i18n) -INSTALL(TARGETS nl_sample_i18n RUNTIME DESTINATION bin COMPONENT samplesmisc) -INSTALL(FILES de.uxt en.uxt fr.uxt DESTINATION share/nel/nl_sample_i18n COMPONENT samplesmisc) +INSTALL(TARGETS nl_sample_i18n RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesmisc) +INSTALL(FILES de.uxt en.uxt fr.uxt DESTINATION ${NL_SHARE_PREFIX}/nl_sample_i18n COMPONENT samplesmisc) diff --git a/code/nel/samples/misc/log/CMakeLists.txt b/code/nel/samples/misc/log/CMakeLists.txt index c106fc00c..dca8c76a8 100644 --- a/code/nel/samples/misc/log/CMakeLists.txt +++ b/code/nel/samples/misc/log/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(nl_sample_log nelmisc) NL_DEFAULT_PROPS(nl_sample_log "NeL, Samples, Misc: Logging") NL_ADD_RUNTIME_FLAGS(nl_sample_log) -INSTALL(TARGETS nl_sample_log RUNTIME DESTINATION bin COMPONENT samplesmisc) +INSTALL(TARGETS nl_sample_log RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesmisc) diff --git a/code/nel/samples/misc/strings/CMakeLists.txt b/code/nel/samples/misc/strings/CMakeLists.txt index e0806591b..d4ffc3c1a 100644 --- a/code/nel/samples/misc/strings/CMakeLists.txt +++ b/code/nel/samples/misc/strings/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(nl_sample_strings nelmisc) NL_DEFAULT_PROPS(nl_sample_strings "NeL, Samples, Misc: Strings") NL_ADD_RUNTIME_FLAGS(nl_sample_strings) -INSTALL(TARGETS nl_sample_strings RUNTIME DESTINATION bin COMPONENT samplesmisc) +INSTALL(TARGETS nl_sample_strings RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesmisc) diff --git a/code/nel/samples/misc/types_check/CMakeLists.txt b/code/nel/samples/misc/types_check/CMakeLists.txt index a8b628979..9b3172eb2 100644 --- a/code/nel/samples/misc/types_check/CMakeLists.txt +++ b/code/nel/samples/misc/types_check/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(nl_sample_types_check nelmisc) NL_DEFAULT_PROPS(nl_sample_types_check "Samples, MISC: Types check sample") NL_ADD_RUNTIME_FLAGS(nl_sample_types_check) -INSTALL(TARGETS nl_sample_types_check RUNTIME DESTINATION bin COMPONENT samplesmisc) +INSTALL(TARGETS nl_sample_types_check RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesmisc) diff --git a/code/nel/samples/net/chat/CMakeLists.txt b/code/nel/samples/net/chat/CMakeLists.txt index a304bced9..b5c66d67c 100644 --- a/code/nel/samples/net/chat/CMakeLists.txt +++ b/code/nel/samples/net/chat/CMakeLists.txt @@ -2,7 +2,7 @@ ADD_EXECUTABLE(nl_sample_chatclient client.cpp kbhit.cpp kbhit.h) ADD_EXECUTABLE(nl_sample_chatserver WIN32 server.cpp) -ADD_DEFINITIONS(-DCHAT_DIR="\\"${NL_SHARE_PREFIX}/nl_sample_chat/\\"") +ADD_DEFINITIONS(-DCHAT_DIR="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_chat/\\"") TARGET_LINK_LIBRARIES(nl_sample_chatclient nelmisc nelnet) NL_DEFAULT_PROPS(nl_sample_chatclient "NeL, Samples, Net, Chat: Chat Client") @@ -12,5 +12,5 @@ TARGET_LINK_LIBRARIES(nl_sample_chatserver nelmisc nelnet) NL_DEFAULT_PROPS(nl_sample_chatserver "NeL, Samples, Net, Chat: Chat Server") NL_ADD_RUNTIME_FLAGS(nl_sample_chatserver) -INSTALL(TARGETS nl_sample_chatclient nl_sample_chatserver RUNTIME DESTINATION bin COMPONENT samplesnet) -INSTALL(FILES chat_service.cfg client.cfg DESTINATION share/nel/nl_sample_chat COMPONENT samplesnet) +INSTALL(TARGETS nl_sample_chatclient nl_sample_chatserver RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesnet) +INSTALL(FILES chat_service.cfg client.cfg DESTINATION ${NL_SHARE_PREFIX}/nl_sample_chat COMPONENT samplesnet) diff --git a/code/nel/samples/net/class_transport/CMakeLists.txt b/code/nel/samples/net/class_transport/CMakeLists.txt index 9da1020ce..3561221d4 100644 --- a/code/nel/samples/net/class_transport/CMakeLists.txt +++ b/code/nel/samples/net/class_transport/CMakeLists.txt @@ -2,7 +2,7 @@ ADD_EXECUTABLE(nl_sample_ct_ai_service WIN32 ai_service.cpp) ADD_EXECUTABLE(nl_sample_ct_gd_service WIN32 gd_service.cpp) -ADD_DEFINITIONS(-DNL_CT_CFG="\\"${NL_SHARE_PREFIX}/nl_sample_class_transport/\\"") +ADD_DEFINITIONS(-DNL_CT_CFG="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_class_transport/\\"") TARGET_LINK_LIBRARIES(nl_sample_ct_ai_service nelmisc nelnet) NL_DEFAULT_PROPS(nl_sample_ct_ai_service "NeL, Samples, Net, Class Transport: AI Service") @@ -12,5 +12,5 @@ TARGET_LINK_LIBRARIES(nl_sample_ct_gd_service nelmisc nelnet) NL_DEFAULT_PROPS(nl_sample_ct_gd_service "NeL, Samples, Net, Class Transport: GD Service") NL_ADD_RUNTIME_FLAGS(nl_sample_ct_gd_service) -INSTALL(TARGETS nl_sample_ct_ai_service nl_sample_ct_gd_service RUNTIME DESTINATION bin COMPONENT samplesnet) -INSTALL(FILES ai_service.cfg gd_service.cfg DESTINATION share/nel/nl_sample_class_transport COMPONENT samplesnet) +INSTALL(TARGETS nl_sample_ct_ai_service nl_sample_ct_gd_service RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesnet) +INSTALL(FILES ai_service.cfg gd_service.cfg DESTINATION ${NL_SHARE_PREFIX}/nl_sample_class_transport COMPONENT samplesnet) diff --git a/code/nel/samples/net/login_system/CMakeLists.txt b/code/nel/samples/net/login_system/CMakeLists.txt index 6ee987e0d..97436fc90 100644 --- a/code/nel/samples/net/login_system/CMakeLists.txt +++ b/code/nel/samples/net/login_system/CMakeLists.txt @@ -2,7 +2,7 @@ ADD_EXECUTABLE(nl_sample_ls_client client.cpp) ADD_EXECUTABLE(nl_sample_ls_fes WIN32 frontend_service.cpp) -ADD_DEFINITIONS(-DNL_LS_CFG="\\"${NL_SHARE_PREFIX}/nl_sample_login_system/\\"") +ADD_DEFINITIONS(-DNL_LS_CFG="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_login_system/\\"") TARGET_LINK_LIBRARIES(nl_sample_ls_client nelmisc nelnet) NL_DEFAULT_PROPS(nl_sample_ls_client "NeL, Samples, Net, Login Service: LS Client") @@ -12,5 +12,5 @@ TARGET_LINK_LIBRARIES(nl_sample_ls_fes nelmisc nelnet) NL_DEFAULT_PROPS(nl_sample_ls_fes "NeL, Samples, Net, Login Service: LS Frontend") NL_ADD_RUNTIME_FLAGS(nl_sample_ls_fes) -INSTALL(TARGETS nl_sample_ls_client nl_sample_ls_fes RUNTIME DESTINATION bin COMPONENT samplesnet) -INSTALL(FILES frontend_service.cfg client.cfg DESTINATION share/nel/nl_sample_login_system COMPONENT samplesnet) +INSTALL(TARGETS nl_sample_ls_client nl_sample_ls_fes RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesnet) +INSTALL(FILES frontend_service.cfg client.cfg DESTINATION ${NL_SHARE_PREFIX}/nl_sample_login_system COMPONENT samplesnet) diff --git a/code/nel/samples/net/udp/CMakeLists.txt b/code/nel/samples/net/udp/CMakeLists.txt index 9daaa9bc0..a4528c4db 100644 --- a/code/nel/samples/net/udp/CMakeLists.txt +++ b/code/nel/samples/net/udp/CMakeLists.txt @@ -4,7 +4,7 @@ ADD_EXECUTABLE(nl_sample_udpclient client.cpp graph.cpp graph.h simlag.cpp simla ADD_EXECUTABLE(nl_sample_udpserver WIN32 bench_service.cpp receive_task.cpp receive_task.h) -ADD_DEFINITIONS(-DUDP_DIR="\\"${NL_SHARE_PREFIX}/nl_sample_udp/\\"") +ADD_DEFINITIONS(-DUDP_DIR="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_udp/\\"") IF(WITH_3D) ADD_DEFINITIONS(-DUSE_3D) @@ -17,9 +17,9 @@ NL_DEFAULT_PROPS(nl_sample_udpserver "NeL, Samples, Net, UDP: UDP Server") NL_ADD_RUNTIME_FLAGS(nl_sample_udpclient) NL_ADD_RUNTIME_FLAGS(nl_sample_udpserver) -INSTALL(TARGETS nl_sample_udpclient nl_sample_udpserver RUNTIME DESTINATION bin COMPONENT samplesnet) -INSTALL(FILES bench_service.cfg client.cfg readme.txt DESTINATION share/nel/nl_sample_udp COMPONENT samplesnet) +INSTALL(TARGETS nl_sample_udpclient nl_sample_udpserver RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplesnet) +INSTALL(FILES bench_service.cfg client.cfg readme.txt DESTINATION ${NL_SHARE_PREFIX}/nl_sample_udp COMPONENT samplesnet) IF(WITH_3D) - INSTALL(FILES n019003l.pfb DESTINATION share/nel/nl_sample_udp COMPONENT samplesnet) + INSTALL(FILES n019003l.pfb DESTINATION ${NL_SHARE_PREFIX}/nl_sample_udp COMPONENT samplesnet) ENDIF(WITH_3D) diff --git a/code/nel/samples/pacs/CMakeLists.txt b/code/nel/samples/pacs/CMakeLists.txt index 96423f7ca..79839c126 100644 --- a/code/nel/samples/pacs/CMakeLists.txt +++ b/code/nel/samples/pacs/CMakeLists.txt @@ -2,16 +2,16 @@ FILE(GLOB SRC *.cpp *.h) ADD_EXECUTABLE(nl_sample_pacs WIN32 ${SRC}) -ADD_DEFINITIONS(-DNL_PACS_DATA="\\"${NL_SHARE_PREFIX}/nl_sample_pacs/\\"") +ADD_DEFINITIONS(-DNL_PACS_DATA="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_pacs/\\"") TARGET_LINK_LIBRARIES(nl_sample_pacs nelmisc nelpacs nel3d) NL_DEFAULT_PROPS(nl_sample_pacs "NeL, Samples: PACS") NL_ADD_RUNTIME_FLAGS(nl_sample_pacs) -INSTALL(TARGETS nl_sample_pacs RUNTIME DESTINATION bin COMPONENT samplespacs) -INSTALL(FILES readme.txt DESTINATION share/nel/nl_sample_pacs COMPONENT samplespacs) +INSTALL(TARGETS nl_sample_pacs RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplespacs) +INSTALL(FILES readme.txt DESTINATION ${NL_SHARE_PREFIX}/nl_sample_pacs COMPONENT samplespacs) INSTALL(DIRECTORY shapes/ - DESTINATION share/nel/nl_sample_pacs/shapes + DESTINATION ${NL_SHARE_PREFIX}/nl_sample_pacs/shapes COMPONENT samplespacs PATTERN "CVS" EXCLUDE PATTERN ".svn" EXCLUDE diff --git a/code/nel/samples/sound/sound_sources/CMakeLists.txt b/code/nel/samples/sound/sound_sources/CMakeLists.txt index 0c680b740..f484c1b76 100644 --- a/code/nel/samples/sound/sound_sources/CMakeLists.txt +++ b/code/nel/samples/sound/sound_sources/CMakeLists.txt @@ -2,7 +2,7 @@ FILE(GLOB SRC *.cpp *.h) ADD_EXECUTABLE(nl_sample_sound_sources ${SRC}) -ADD_DEFINITIONS(-DNL_SOUND_DATA="\\"${NL_SHARE_PREFIX}/nl_sample_sound/\\"" ${LIBXML2_DEFINITIONS}) +ADD_DEFINITIONS(-DNL_SOUND_DATA="\\"${NL_SHARE_ABSOLUTE_PREFIX}/nl_sample_sound/\\"" ${LIBXML2_DEFINITIONS}) INCLUDE_DIRECTORIES(${LIBXML2_INCLUDE_DIR}) @@ -10,9 +10,9 @@ TARGET_LINK_LIBRARIES(nl_sample_sound_sources nelmisc nelsound) NL_DEFAULT_PROPS(nl_sample_sound_sources "NeL, Samples: Sound: Sound Sources") NL_ADD_RUNTIME_FLAGS(nl_sample_sound_sources) -INSTALL(TARGETS nl_sample_sound_sources RUNTIME DESTINATION bin COMPONENT samplessound) +INSTALL(TARGETS nl_sample_sound_sources RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplessound) INSTALL(DIRECTORY data/ - DESTINATION share/nel/nl_sample_sound/data + DESTINATION ${NL_SHARE_PREFIX}/nl_sample_sound/data COMPONENT samplespacs PATTERN "CVS" EXCLUDE PATTERN ".svn" EXCLUDE diff --git a/code/nel/samples/sound/stream_file/CMakeLists.txt b/code/nel/samples/sound/stream_file/CMakeLists.txt index 5bd39cdb1..e3afd814d 100644 --- a/code/nel/samples/sound/stream_file/CMakeLists.txt +++ b/code/nel/samples/sound/stream_file/CMakeLists.txt @@ -8,5 +8,5 @@ TARGET_LINK_LIBRARIES(nl_sample_stream_file nelmisc nelsound) NL_DEFAULT_PROPS(nl_sample_stream_file "NeL, Samples: Sound: Stream File") NL_ADD_RUNTIME_FLAGS(nl_sample_stream_file) -INSTALL(TARGETS nl_sample_stream_file RUNTIME DESTINATION bin COMPONENT samplessound) +INSTALL(TARGETS nl_sample_stream_file RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplessound) diff --git a/code/nel/samples/sound/stream_ogg_vorbis/CMakeLists.txt b/code/nel/samples/sound/stream_ogg_vorbis/CMakeLists.txt index 6a80d2db7..62f446290 100644 --- a/code/nel/samples/sound/stream_ogg_vorbis/CMakeLists.txt +++ b/code/nel/samples/sound/stream_ogg_vorbis/CMakeLists.txt @@ -8,5 +8,5 @@ TARGET_LINK_LIBRARIES(nl_sample_stream_ogg_vorbis nelmisc nelsound) NL_DEFAULT_PROPS(nl_sample_stream_ogg_vorbis "NeL, Samples: Sound: Stream OGG Vorbis") NL_ADD_RUNTIME_FLAGS(nl_sample_stream_ogg_vorbis) -INSTALL(TARGETS nl_sample_stream_ogg_vorbis RUNTIME DESTINATION bin COMPONENT samplessound) +INSTALL(TARGETS nl_sample_stream_ogg_vorbis RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT samplessound) diff --git a/code/nel/src/3d/CMakeLists.txt b/code/nel/src/3d/CMakeLists.txt index 787cc189d..6f632e261 100644 --- a/code/nel/src/3d/CMakeLists.txt +++ b/code/nel/src/3d/CMakeLists.txt @@ -708,7 +708,7 @@ ENDIF(WITH_PCH) NL_GEN_PC(nel-3d.pc) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) - INSTALL(TARGETS nel3d LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) + INSTALL(TARGETS nel3d LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) ADD_SUBDIRECTORY(driver) diff --git a/code/nel/src/3d/driver/direct3d/CMakeLists.txt b/code/nel/src/3d/driver/direct3d/CMakeLists.txt index fd26c438a..ede76f06c 100644 --- a/code/nel/src/3d/driver/direct3d/CMakeLists.txt +++ b/code/nel/src/3d/driver/direct3d/CMakeLists.txt @@ -17,7 +17,7 @@ IF(WITH_PCH) ENDIF(WITH_PCH) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC_DRIVERS) OR NOT WITH_STATIC_DRIVERS) - INSTALL(TARGETS nel_drv_direct3d_win LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION lib RUNTIME DESTINATION bin COMPONENT drivers3d) + INSTALL(TARGETS nel_drv_direct3d_win LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} RUNTIME DESTINATION ${NL_DRIVER_PREFIX} COMPONENT drivers3d) IF(WITH_MAXPLUGIN) INSTALL(TARGETS nel_drv_direct3d_win RUNTIME DESTINATION maxplugin COMPONENT drivers3d) ENDIF(WITH_MAXPLUGIN) diff --git a/code/nel/src/3d/driver/direct3d/driver_direct3d.cpp b/code/nel/src/3d/driver/direct3d/driver_direct3d.cpp index 3a542687a..2b18c8698 100644 --- a/code/nel/src/3d/driver/direct3d/driver_direct3d.cpp +++ b/code/nel/src/3d/driver/direct3d/driver_direct3d.cpp @@ -2715,6 +2715,8 @@ bool CDriverD3D::fillPresentParameter (D3DPRESENT_PARAMETERS ¶meters, D3DFOR // Choose a zbuffer format D3DFORMAT zbufferFormats[]= { + //uncomment to save zbuffer D3DFMT_D32F_LOCKABLE, + //uncomment to save zbuffer D3DFMT_D16_LOCKABLE, /*D3DFMT_D32, D3DFMT_D24X8,*/ D3DFMT_D24S8, diff --git a/code/nel/src/3d/driver/direct3d/driver_direct3d_texture.cpp b/code/nel/src/3d/driver/direct3d/driver_direct3d_texture.cpp index 2cd16bf1c..cfafaf5f9 100644 --- a/code/nel/src/3d/driver/direct3d/driver_direct3d_texture.cpp +++ b/code/nel/src/3d/driver/direct3d/driver_direct3d_texture.cpp @@ -442,7 +442,7 @@ bool CDriverD3D::generateD3DTexture (ITexture& tex, bool textureDegradation, D3D if (d3dtext->Texture == NULL) { // profiling: count TextureMemory usage. - uint32 textureMeory = computeTextureMemoryUsage (width, height, levels, destFormat, cube); + uint32 textureMemory = computeTextureMemoryUsage (width, height, levels, destFormat, cube); // Create the texture bool createSuccess; @@ -465,7 +465,14 @@ bool CDriverD3D::generateD3DTexture (ITexture& tex, bool textureDegradation, D3D _DeviceInterface->SetSamplerState(0, D3DSAMP_ADDRESSW, D3DTADDRESS_CLAMP); } - createSuccess = _DeviceInterface->CreateTexture (width, height, levels, renderTarget?D3DUSAGE_RENDERTARGET:0, destFormat, renderTarget?D3DPOOL_DEFAULT:D3DPOOL_MANAGED, &(d3dtext->Texture2d), NULL) == D3D_OK; + HRESULT hr = _DeviceInterface->CreateTexture (width, height, levels, renderTarget?D3DUSAGE_RENDERTARGET:0, destFormat, renderTarget?D3DPOOL_DEFAULT:D3DPOOL_MANAGED, &(d3dtext->Texture2d), NULL); + + if (hr != D3D_OK) + { + nlwarning("CreateTexture failed with code 0x%x for texture %s in %ux%u", hr, tex.getShareName().c_str(), width, height); + } + + createSuccess = hr == D3D_OK; d3dtext->Texture = d3dtext->Texture2d; } @@ -473,7 +480,7 @@ bool CDriverD3D::generateD3DTexture (ITexture& tex, bool textureDegradation, D3D return false; // Stats - d3dtext->TextureMemory = textureMeory; + d3dtext->TextureMemory = textureMemory; _AllocatedTextureMemory += d3dtext->TextureMemory; // Copy parameters diff --git a/code/nel/src/3d/driver/opengl/CMakeLists.txt b/code/nel/src/3d/driver/opengl/CMakeLists.txt index d68bef5f2..8fa99d488 100644 --- a/code/nel/src/3d/driver/opengl/CMakeLists.txt +++ b/code/nel/src/3d/driver/opengl/CMakeLists.txt @@ -74,7 +74,7 @@ IF(WITH_PCH) ENDIF(WITH_PCH) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC_DRIVERS) OR NOT WITH_STATIC_DRIVERS) - INSTALL(TARGETS ${NLDRV_OGL_LIB} LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION lib RUNTIME DESTINATION bin COMPONENT drivers3d) + INSTALL(TARGETS ${NLDRV_OGL_LIB} LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} RUNTIME DESTINATION ${NL_DRIVER_PREFIX} COMPONENT drivers3d) IF(WITH_MAXPLUGIN) INSTALL(TARGETS ${NLDRV_OGL_LIB} RUNTIME DESTINATION maxplugin COMPONENT drivers3d) ENDIF(WITH_MAXPLUGIN) diff --git a/code/nel/src/3d/driver/opengl/driver_opengl_vertex_program.cpp b/code/nel/src/3d/driver/opengl/driver_opengl_vertex_program.cpp index ae47ac7ec..dc2a4243a 100644 --- a/code/nel/src/3d/driver/opengl/driver_opengl_vertex_program.cpp +++ b/code/nel/src/3d/driver/opengl/driver_opengl_vertex_program.cpp @@ -43,7 +43,8 @@ namespace NLDRIVERGL { // *************************************************************************** CVertexProgamDrvInfosGL::CVertexProgamDrvInfosGL (CDriverGL *drv, ItVtxPrgDrvInfoPtrList it) : IVertexProgramDrvInfos (drv, it) { - H_AUTO_OGL(CVertexProgamDrvInfosGL_CVertexProgamDrvInfosGL) + H_AUTO_OGL(CVertexProgamDrvInfosGL_CVertexProgamDrvInfosGL); + // Extension must exist nlassert (drv->_Extensions.NVVertexProgram || drv->_Extensions.EXTVertexShader @@ -87,7 +88,7 @@ bool CDriverGL::isVertexProgramEmulated () const // *************************************************************************** bool CDriverGL::activeNVVertexProgram (CVertexProgram *program) { - H_AUTO_OGL(CVertexProgamDrvInfosGL_activeNVVertexProgram) + H_AUTO_OGL(CVertexProgamDrvInfosGL_activeNVVertexProgram); #ifndef USE_OPENGLES // Setup or unsetup ? @@ -209,7 +210,8 @@ bool CDriverGL::activeNVVertexProgram (CVertexProgram *program) static inline GLenum convSwizzleToGLFormat(CVPSwizzle::EComp comp, bool negate) { - H_AUTO_OGL(convSwizzleToGLFormat) + H_AUTO_OGL(convSwizzleToGLFormat); + if (!negate) { switch(comp) @@ -1348,12 +1350,10 @@ static void ARBVertexProgramDumpInstr(const CVPInstruction &instr, std::string & } - - // *************************************************************************** bool CDriverGL::setupARBVertexProgram (const CVPParser::TProgram &inParsedProgram, GLuint id, bool &specularWritten) { - H_AUTO_OGL(CDriverGL_setupARBVertexProgram) + H_AUTO_OGL(CDriverGL_setupARBVertexProgram); #ifndef USE_OPENGLES // tmp @@ -1571,7 +1571,6 @@ bool CDriverGL::activeARBVertexProgram (CVertexProgram *program) #endif } - // *************************************************************************** bool CDriverGL::activeEXTVertexShader (CVertexProgram *program) { diff --git a/code/nel/src/3d/driver/opengl/nel-driverogl.pc b/code/nel/src/3d/driver/opengl/nel-driverogl.pc index 867ad515e..03a2b1294 100644 --- a/code/nel/src/3d/driver/opengl/nel-driverogl.pc +++ b/code/nel/src/3d/driver/opengl/nel-driverogl.pc @@ -6,7 +6,7 @@ includedir=${prefix}/include Name: nel-driverogl Version: 0.5.0 Description: NeL 0.5.0 -Reqiures: +Requires: Libs: -L${libdir} Libs.private: -ldl -lpthread -lxml2 -lGL -lXxf86vm -lXmu Cflags: -I${includedir} -DXF86VIDMODE diff --git a/code/nel/src/3d/driver/opengl/nel-driverogl.pc.in b/code/nel/src/3d/driver/opengl/nel-driverogl.pc.in index 282e580f1..6f43c5f14 100644 --- a/code/nel/src/3d/driver/opengl/nel-driverogl.pc.in +++ b/code/nel/src/3d/driver/opengl/nel-driverogl.pc.in @@ -6,7 +6,7 @@ includedir=@includedir@ Name: nel-driverogl Version: @VERSION@ Description: NeL @VERSION@ -Reqiures: +Requires: Libs: -L${libdir} Libs.private: @LIBS@ @OPENGL_LIBS@ @XF86VIDMODE_LIBS@ -lXmu Cflags: -I${includedir} @OPENGL_CFLAGS@ @XF86VIDMODE_CFLAGS@ diff --git a/code/nel/src/3d/driver/opengles/CMakeLists.txt b/code/nel/src/3d/driver/opengles/CMakeLists.txt index bd330c6ec..74f0ddff3 100644 --- a/code/nel/src/3d/driver/opengles/CMakeLists.txt +++ b/code/nel/src/3d/driver/opengles/CMakeLists.txt @@ -77,7 +77,7 @@ IF(WITH_PCH) ENDIF(WITH_PCH) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC_DRIVERS) OR NOT WITH_STATIC_DRIVERS) - INSTALL(TARGETS ${NLDRV_OGLES_LIB} LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION lib RUNTIME DESTINATION bin COMPONENT drivers3d) + INSTALL(TARGETS ${NLDRV_OGLES_LIB} LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} RUNTIME DESTINATION ${NL_DRIVER_PREFIX} COMPONENT drivers3d) IF(WITH_MAXPLUGIN) INSTALL(TARGETS ${NLDRV_OGLES_LIB} RUNTIME DESTINATION maxplugin COMPONENT drivers3d) ENDIF(WITH_MAXPLUGIN) diff --git a/code/nel/src/3d/nel-3d.pc b/code/nel/src/3d/nel-3d.pc index 638961276..9420c67bf 100644 --- a/code/nel/src/3d/nel-3d.pc +++ b/code/nel/src/3d/nel-3d.pc @@ -6,7 +6,7 @@ includedir=${prefix}/include Name: nel-3d Version: 0.5.0 Description: NeL 0.5.0 -Reqiures: +Requires: Libs: -L${libdir} Libs.private: -ldl -lpthread -lxml2 -lfreetype -lz -lc Cflags: -I${includedir} -I/usr/include/freetype2 diff --git a/code/nel/src/3d/nel-3d.pc.in b/code/nel/src/3d/nel-3d.pc.in index ade3e2d08..a3c06762a 100644 --- a/code/nel/src/3d/nel-3d.pc.in +++ b/code/nel/src/3d/nel-3d.pc.in @@ -6,7 +6,7 @@ includedir=@includedir@ Name: nel-3d Version: @NL_VERSION@ Description: NeL @NL_VERSION@ -Reqiures: +Requires: Libs: -L${libdir} Libs.private: @LIBS@ @FREETYPE_LIBS@ -lc Cflags: -I${includedir} @FREETYPE_CFLAGS@ diff --git a/code/nel/src/3d/tangent_space_build.cpp b/code/nel/src/3d/tangent_space_build.cpp index 17e106615..8a1b1100a 100644 --- a/code/nel/src/3d/tangent_space_build.cpp +++ b/code/nel/src/3d/tangent_space_build.cpp @@ -214,9 +214,9 @@ bool BuildTangentSpace(CMesh::CMeshBuild &outMeshBuild, const CMesh::CMeshBuild if (!canShare) continue; // Get indices of vertices of current tri - const uint indices[] = { f.Corner[0].Vertex, - f.Corner[1].Vertex, - f.Corner[2].Vertex }; + const uint indices[] = { (uint)f.Corner[0].Vertex, + (uint)f.Corner[1].Vertex, + (uint)f.Corner[2].Vertex }; NLMISC::CTriangle tri; // Build it BuildTriFromMB(outMeshBuild, indices, tri); diff --git a/code/nel/src/cegui/CMakeLists.txt b/code/nel/src/cegui/CMakeLists.txt index 48c06eb4b..b815eb139 100644 --- a/code/nel/src/cegui/CMakeLists.txt +++ b/code/nel/src/cegui/CMakeLists.txt @@ -12,5 +12,5 @@ NL_ADD_LIB_SUFFIX(nelceguirenderer) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DNEL_CEGUIRENDERER_EXPORTS) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) - INSTALL(TARGETS nelceguirenderer RUNTIME DESTINATION bin LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) + INSTALL(TARGETS nelceguirenderer RUNTIME DESTINATION ${NL_BIN_PREFIX} LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) diff --git a/code/nel/src/georges/CMakeLists.txt b/code/nel/src/georges/CMakeLists.txt index 640f33204..1d56a31bf 100644 --- a/code/nel/src/georges/CMakeLists.txt +++ b/code/nel/src/georges/CMakeLists.txt @@ -23,5 +23,5 @@ ENDIF(WITH_PCH) NL_GEN_PC(nel-georges.pc) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) - INSTALL(TARGETS nelgeorges LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) + INSTALL(TARGETS nelgeorges LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) diff --git a/code/nel/src/georges/nel-georges.pc.in b/code/nel/src/georges/nel-georges.pc.in index 4aa509aa0..5a8703714 100644 --- a/code/nel/src/georges/nel-georges.pc.in +++ b/code/nel/src/georges/nel-georges.pc.in @@ -6,7 +6,7 @@ includedir=@includedir@ Name: nel-georges Version: @NL_VERSION@ Description: NeL @NL_VERSION@ -Reqiures: +Requires: Libs: -L${libdir} Libs.private: @LIBS@ -lc Cflags: -I${includedir} diff --git a/code/nel/src/ligo/CMakeLists.txt b/code/nel/src/ligo/CMakeLists.txt index 41b0eaaa1..4c1bfbc30 100644 --- a/code/nel/src/ligo/CMakeLists.txt +++ b/code/nel/src/ligo/CMakeLists.txt @@ -21,5 +21,5 @@ ENDIF(WITH_PCH) NL_GEN_PC(nel-ligo.pc) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) - INSTALL(TARGETS nelligo LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) + INSTALL(TARGETS nelligo LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) diff --git a/code/nel/src/ligo/nel-ligo.pc.in b/code/nel/src/ligo/nel-ligo.pc.in index d4a535bac..dfe27ceac 100644 --- a/code/nel/src/ligo/nel-ligo.pc.in +++ b/code/nel/src/ligo/nel-ligo.pc.in @@ -6,7 +6,7 @@ includedir=@includedir@ Name: nel-ligo Version: @NL_VERSION@ Description: NeL @NL_VERSION@ -Reqiures: +Requires: Libs: -L${libdir} Libs.private: @LIBS@ -lc Cflags: -I${includedir} diff --git a/code/nel/src/logic/CMakeLists.txt b/code/nel/src/logic/CMakeLists.txt index 5ee2b682d..ea0ca605f 100644 --- a/code/nel/src/logic/CMakeLists.txt +++ b/code/nel/src/logic/CMakeLists.txt @@ -15,5 +15,5 @@ NL_ADD_LIB_SUFFIX(nellogic) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) - INSTALL(TARGETS nellogic LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) + INSTALL(TARGETS nellogic LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) diff --git a/code/nel/src/misc/CMakeLists.txt b/code/nel/src/misc/CMakeLists.txt index ff6057b6f..dc5b87e2c 100644 --- a/code/nel/src/misc/CMakeLists.txt +++ b/code/nel/src/misc/CMakeLists.txt @@ -55,5 +55,5 @@ ENDIF(WITH_PCH) NL_GEN_PC(nel-misc.pc) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) - INSTALL(TARGETS nelmisc LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) + INSTALL(TARGETS nelmisc LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) diff --git a/code/nel/src/misc/eval_num_expr.cpp b/code/nel/src/misc/eval_num_expr.cpp index cf543c260..de7f3b2bf 100644 --- a/code/nel/src/misc/eval_num_expr.cpp +++ b/code/nel/src/misc/eval_num_expr.cpp @@ -1309,7 +1309,7 @@ const int CEvalNumExpr::_OperatorPrecedence[]= 9, // LogicalAnd 10, // LogicalOr 11, // LogicalXor - 0xffffffff, // OperatorCount + -1, // OperatorCount 20, // NotOperator }; diff --git a/code/nel/src/misc/i18n.cpp b/code/nel/src/misc/i18n.cpp index 92da17250..c68b190c5 100644 --- a/code/nel/src/misc/i18n.cpp +++ b/code/nel/src/misc/i18n.cpp @@ -914,9 +914,9 @@ void CI18N::_readTextFile(const string &filename, void CI18N::readTextBuffer(uint8 *buffer, uint size, ucstring &result, bool forceUtf8) { - static uint8 utf16Header[] = {char(0xff), char(0xfe)}; - static uint8 utf16RevHeader[] = {char(0xfe), char(0xff)}; - static uint8 utf8Header[] = {char(0xef), char(0xbb), char(0xbf)}; + static uint8 utf16Header[] = { 0xffu, 0xfeu }; + static uint8 utf16RevHeader[] = { 0xfeu, 0xffu }; + static uint8 utf8Header[] = { 0xefu, 0xbbu, 0xbfu }; if (forceUtf8) { diff --git a/code/nel/src/misc/nel-misc.pc b/code/nel/src/misc/nel-misc.pc index db7c97b22..4d28291ed 100644 --- a/code/nel/src/misc/nel-misc.pc +++ b/code/nel/src/misc/nel-misc.pc @@ -6,7 +6,7 @@ includedir=${prefix}/include Name: nel-misc Version: 0.5.0 Description: NeL 0.5.0 -Reqiures: +Requires: Libs: -L${libdir} Libs.private: -ldl -lpthread -lxml2 -lc -lpthread -lrt -ldl Cflags: -I${includedir} -lc -lpthread -lrt -ldl diff --git a/code/nel/src/misc/nel-misc.pc.in b/code/nel/src/misc/nel-misc.pc.in index c4d447c42..abea860a1 100644 --- a/code/nel/src/misc/nel-misc.pc.in +++ b/code/nel/src/misc/nel-misc.pc.in @@ -6,7 +6,7 @@ includedir=@includedir@ Name: nel-misc Version: @NL_VERSION@ Description: NeL @NL_VERSION@ -Reqiures: +Requires: Libs: -L${libdir} Libs.private: @LIBS@ -lc -lpthread -lrt -ldl Cflags: -I${includedir} -lc -lpthread -lrt -ldl diff --git a/code/nel/src/misc/sheet_id.cpp b/code/nel/src/misc/sheet_id.cpp index 0ff90b1f8..9a9b8813f 100644 --- a/code/nel/src/misc/sheet_id.cpp +++ b/code/nel/src/misc/sheet_id.cpp @@ -157,7 +157,7 @@ bool CSheetId::buildSheetId(const std::string& sheetName) { _FileExtensions.push_back(sheetType); _DevSheetIdToName.push_back(std::vector()); - typeId = _FileExtensions.size() - 1; + typeId = (uint32)_FileExtensions.size() - 1; _DevTypeNameToId[sheetType] = typeId; std::string unknownNewType = std::string("unknown." + sheetType); _DevSheetIdToName[typeId].push_back(unknownNewType); diff --git a/code/nel/src/misc/time_nl.cpp b/code/nel/src/misc/time_nl.cpp index dd43fd2f7..422ba192f 100644 --- a/code/nel/src/misc/time_nl.cpp +++ b/code/nel/src/misc/time_nl.cpp @@ -280,11 +280,17 @@ void CTime::probeTimerInfo(CTime::CTimerInfo &result) else result.RequiresSingleCore = false; if (result.HighPrecisionResolution == 14318180) + { nldebug("Detected known HPET era timer frequency"); + } if (result.HighPrecisionResolution == 3579545) + { nldebug("Detected known AHCI era timer frequency"); + } if (result.HighPrecisionResolution == 1193182) + { nldebug("Detected known i8253/i8254 era timer frequency"); + } } } diff --git a/code/nel/src/net/CMakeLists.txt b/code/nel/src/net/CMakeLists.txt index f30232e8d..487516e74 100644 --- a/code/nel/src/net/CMakeLists.txt +++ b/code/nel/src/net/CMakeLists.txt @@ -26,5 +26,5 @@ ENDIF(WITH_PCH) NL_GEN_PC(nel-net.pc) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) - INSTALL(TARGETS nelnet LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) + INSTALL(TARGETS nelnet LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) diff --git a/code/nel/src/net/nel-net.pc.in b/code/nel/src/net/nel-net.pc.in index 0fb2a0462..cbbf7ab50 100644 --- a/code/nel/src/net/nel-net.pc.in +++ b/code/nel/src/net/nel-net.pc.in @@ -6,7 +6,7 @@ includedir=@includedir@ Name: nel-net Version: @NL_VERSION@ Description: NeL @NL_VERSION@ -Reqiures: +Requires: Libs: -L${libdir} Libs.private: @LIBS@ -lc -lpthread -lrt -ldl Cflags: -I${includedir} -lc -lpthread -lrt -ldl diff --git a/code/nel/src/pacs/CMakeLists.txt b/code/nel/src/pacs/CMakeLists.txt index 492df88be..1fde3e6df 100644 --- a/code/nel/src/pacs/CMakeLists.txt +++ b/code/nel/src/pacs/CMakeLists.txt @@ -21,5 +21,5 @@ ENDIF(WITH_PCH) NL_GEN_PC(nel-pacs.pc) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) - INSTALL(TARGETS nelpacs LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) + INSTALL(TARGETS nelpacs LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) diff --git a/code/nel/src/pacs/nel-pacs.pc.in b/code/nel/src/pacs/nel-pacs.pc.in index 133b51d53..e1729f105 100644 --- a/code/nel/src/pacs/nel-pacs.pc.in +++ b/code/nel/src/pacs/nel-pacs.pc.in @@ -6,7 +6,7 @@ includedir=@includedir@ Name: nel-pacs Version: @NL_VERSION@ Description: NeL @NL_VERSION@ -Reqiures: +Requires: Libs: -L${libdir} Libs.private: @LIBS@ -lc -lpthread -lrt -ldl Cflags: -I${includedir} -lc -lpthread -lrt -ldl diff --git a/code/nel/src/sound/CMakeLists.txt b/code/nel/src/sound/CMakeLists.txt index 1122551cc..9d2e0dd82 100644 --- a/code/nel/src/sound/CMakeLists.txt +++ b/code/nel/src/sound/CMakeLists.txt @@ -114,7 +114,7 @@ ENDIF(WITH_PCH) NL_GEN_PC(nel-sound.pc) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) - INSTALL(TARGETS nelsound LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) + INSTALL(TARGETS nelsound LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) ADD_SUBDIRECTORY(driver) diff --git a/code/nel/src/sound/driver/CMakeLists.txt b/code/nel/src/sound/driver/CMakeLists.txt index 68ad208bb..64e73cb1d 100644 --- a/code/nel/src/sound/driver/CMakeLists.txt +++ b/code/nel/src/sound/driver/CMakeLists.txt @@ -17,7 +17,7 @@ IF(WITH_PCH) ENDIF(WITH_PCH) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) - INSTALL(TARGETS nelsnd_lowlevel LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) + INSTALL(TARGETS nelsnd_lowlevel LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) IF(WITH_DRIVER_OPENAL) diff --git a/code/nel/src/sound/driver/dsound/CMakeLists.txt b/code/nel/src/sound/driver/dsound/CMakeLists.txt index 284b9eeae..74d431084 100644 --- a/code/nel/src/sound/driver/dsound/CMakeLists.txt +++ b/code/nel/src/sound/driver/dsound/CMakeLists.txt @@ -14,7 +14,7 @@ IF(WITH_PCH) ENDIF(WITH_PCH) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC_DRIVERS) OR NOT WITH_STATIC_DRIVERS) - INSTALL(TARGETS nel_drv_dsound_win RUNTIME DESTINATION bin LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION lib COMPONENT driverssound) + INSTALL(TARGETS nel_drv_dsound_win RUNTIME DESTINATION ${NL_DRIVER_PREFIX} LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT driverssound) IF(WITH_MAXPLUGIN) INSTALL(TARGETS nel_drv_dsound_win RUNTIME DESTINATION maxplugin COMPONENT driverssound) ENDIF(WITH_MAXPLUGIN) diff --git a/code/nel/src/sound/driver/fmod/CMakeLists.txt b/code/nel/src/sound/driver/fmod/CMakeLists.txt index 982c24bca..d8ee31ba7 100644 --- a/code/nel/src/sound/driver/fmod/CMakeLists.txt +++ b/code/nel/src/sound/driver/fmod/CMakeLists.txt @@ -14,7 +14,7 @@ IF(WITH_PCH) ENDIF(WITH_PCH) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC_DRIVERS) OR NOT WITH_STATIC_DRIVERS) - INSTALL(TARGETS nel_drv_fmod_win RUNTIME DESTINATION bin LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION lib COMPONENT driverssound) + INSTALL(TARGETS nel_drv_fmod_win RUNTIME DESTINATION ${NL_DRIVER_PREFIX} LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT driverssound) IF(WITH_MAXPLUGIN) INSTALL(TARGETS nel_drv_fmod_win RUNTIME DESTINATION maxplugin COMPONENT driverssound) ENDIF(WITH_MAXPLUGIN) diff --git a/code/nel/src/sound/driver/openal/CMakeLists.txt b/code/nel/src/sound/driver/openal/CMakeLists.txt index 5e3fcb90b..adf2b584f 100644 --- a/code/nel/src/sound/driver/openal/CMakeLists.txt +++ b/code/nel/src/sound/driver/openal/CMakeLists.txt @@ -45,7 +45,7 @@ IF(WITH_PCH) ENDIF(WITH_PCH) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC_DRIVERS) OR NOT WITH_STATIC_DRIVERS) - INSTALL(TARGETS ${NLDRV_AL_LIB} RUNTIME DESTINATION ${NL_DRIVER_PREFIX} LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION lib COMPONENT driverssound) + INSTALL(TARGETS ${NLDRV_AL_LIB} RUNTIME DESTINATION ${NL_DRIVER_PREFIX} LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT driverssound) IF(WITH_MAXPLUGIN) INSTALL(TARGETS ${NLDRV_AL_LIB} RUNTIME DESTINATION maxplugin COMPONENT driverssound) ENDIF(WITH_MAXPLUGIN) diff --git a/code/nel/src/sound/driver/openal/sound_driver_al.cpp b/code/nel/src/sound/driver/openal/sound_driver_al.cpp index 65af8002c..40ea39d0b 100644 --- a/code/nel/src/sound/driver/openal/sound_driver_al.cpp +++ b/code/nel/src/sound/driver/openal/sound_driver_al.cpp @@ -246,7 +246,6 @@ static const ALchar *getDeviceInternal(const std::string &device) if (AlEnumerateAllExt) { const ALchar* deviceNames = alcGetString(NULL, ALC_ALL_DEVICES_SPECIFIER); - // const ALchar* defaultDevice = NULL; if(!strlen(deviceNames)) { nldebug("AL: No audio devices"); @@ -291,6 +290,7 @@ void CSoundDriverAL::initDevice(const std::string &device, ISoundDriver::TSoundO // OpenAL initialization const ALchar *dev = getDeviceInternal(device); + if (!dev) dev = alcGetString(NULL, ALC_DEFAULT_DEVICE_SPECIFIER); nldebug("AL: Opening device: '%s'", dev == NULL ? "NULL" : dev); _AlDevice = alcOpenDevice(dev); if (!_AlDevice) throw ESoundDriver("AL: Failed to open device"); diff --git a/code/nel/src/sound/driver/xaudio2/CMakeLists.txt b/code/nel/src/sound/driver/xaudio2/CMakeLists.txt index c0d49bd5e..9113bd022 100644 --- a/code/nel/src/sound/driver/xaudio2/CMakeLists.txt +++ b/code/nel/src/sound/driver/xaudio2/CMakeLists.txt @@ -41,7 +41,7 @@ IF(WITH_PCH) ENDIF(WITH_PCH) IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC_DRIVERS) OR NOT WITH_STATIC_DRIVERS) - INSTALL(TARGETS nel_drv_xaudio2_win RUNTIME DESTINATION bin LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION lib COMPONENT driverssound) + INSTALL(TARGETS nel_drv_xaudio2_win RUNTIME DESTINATION ${NL_DRIVER_PREFIX} LIBRARY DESTINATION ${NL_DRIVER_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT driverssound) IF(WITH_MAXPLUGIN) INSTALL(TARGETS nel_drv_xaudio2_win RUNTIME DESTINATION maxplugin COMPONENT driverssound) ENDIF(WITH_MAXPLUGIN) diff --git a/code/nel/src/sound/nel-sound.pc.in b/code/nel/src/sound/nel-sound.pc.in index 9994e967e..44ff6e1f0 100644 --- a/code/nel/src/sound/nel-sound.pc.in +++ b/code/nel/src/sound/nel-sound.pc.in @@ -6,7 +6,7 @@ includedir=@includedir@ Name: nel-sound Version: @NL_VERSION@ Description: NeL @NL_VERSION@ -Reqiures: +Requires: Libs: -L${libdir} Libs.private: @LIBS@ -lc -lpthread -lrt -ldl Cflags: -I${includedir} -lc -lpthread -lrt -ldl diff --git a/code/nel/tools/3d/anim_builder/CMakeLists.txt b/code/nel/tools/3d/anim_builder/CMakeLists.txt index fada1485f..61188b461 100644 --- a/code/nel/tools/3d/anim_builder/CMakeLists.txt +++ b/code/nel/tools/3d/anim_builder/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(anim_builder nelmisc nel3d) NL_DEFAULT_PROPS(anim_builder "NeL, Tools, 3D: anim_builder") NL_ADD_RUNTIME_FLAGS(anim_builder) -INSTALL(TARGETS anim_builder RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS anim_builder RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/animation_set_builder/CMakeLists.txt b/code/nel/tools/3d/animation_set_builder/CMakeLists.txt index 8ebf1fff7..da81b1de3 100644 --- a/code/nel/tools/3d/animation_set_builder/CMakeLists.txt +++ b/code/nel/tools/3d/animation_set_builder/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(animation_set_builder nel3d nelmisc) NL_DEFAULT_PROPS(animation_set_builder "NeL, Tools, 3D: anim_set_builder") NL_ADD_RUNTIME_FLAGS(animation_set_builder) -INSTALL(TARGETS animation_set_builder RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS animation_set_builder RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/build_clod_bank/CMakeLists.txt b/code/nel/tools/3d/build_clod_bank/CMakeLists.txt index 3b7704f24..2bd4846d7 100644 --- a/code/nel/tools/3d/build_clod_bank/CMakeLists.txt +++ b/code/nel/tools/3d/build_clod_bank/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(build_clod_bank nel3d nelmisc) NL_DEFAULT_PROPS(build_clod_bank "NeL, Tools, 3D: build_clod_bank") NL_ADD_RUNTIME_FLAGS(build_clod_bank) -INSTALL(TARGETS build_clod_bank RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS build_clod_bank RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/build_clodtex/CMakeLists.txt b/code/nel/tools/3d/build_clodtex/CMakeLists.txt index a6cefc40c..558962421 100644 --- a/code/nel/tools/3d/build_clodtex/CMakeLists.txt +++ b/code/nel/tools/3d/build_clodtex/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(build_clodtex nel3d nelmisc) NL_DEFAULT_PROPS(build_clodtex "NeL, Tools, 3D: build_clodtex") NL_ADD_RUNTIME_FLAGS(build_clodtex) -INSTALL(TARGETS build_clodtex RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS build_clodtex RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/build_coarse_mesh/CMakeLists.txt b/code/nel/tools/3d/build_coarse_mesh/CMakeLists.txt index 2247b01df..93eba1bfc 100644 --- a/code/nel/tools/3d/build_coarse_mesh/CMakeLists.txt +++ b/code/nel/tools/3d/build_coarse_mesh/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(build_coarse_mesh nel3d nelmisc) NL_DEFAULT_PROPS(build_coarse_mesh "NeL, Tools, 3D: build_coarse_mesh") NL_ADD_RUNTIME_FLAGS(build_coarse_mesh) -INSTALL(TARGETS build_coarse_mesh RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS build_coarse_mesh RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/build_far_bank/CMakeLists.txt b/code/nel/tools/3d/build_far_bank/CMakeLists.txt index adc3afb08..7a858d560 100644 --- a/code/nel/tools/3d/build_far_bank/CMakeLists.txt +++ b/code/nel/tools/3d/build_far_bank/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(build_far_bank nel3d nelmisc) NL_DEFAULT_PROPS(build_far_bank "NeL, Tools, 3D: build_far_bank") NL_ADD_RUNTIME_FLAGS(build_far_bank) -INSTALL(TARGETS build_far_bank RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS build_far_bank RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/build_interface/CMakeLists.txt b/code/nel/tools/3d/build_interface/CMakeLists.txt index fc4b853fb..113fe2b84 100644 --- a/code/nel/tools/3d/build_interface/CMakeLists.txt +++ b/code/nel/tools/3d/build_interface/CMakeLists.txt @@ -8,4 +8,4 @@ TARGET_LINK_LIBRARIES(build_interface nelmisc) NL_DEFAULT_PROPS(build_interface "NeL, Tools, 3D: build_interface") NL_ADD_RUNTIME_FLAGS(build_interface) -INSTALL(TARGETS build_interface RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS build_interface RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/build_shadow_skin/CMakeLists.txt b/code/nel/tools/3d/build_shadow_skin/CMakeLists.txt index 60cc83980..78bbd712d 100644 --- a/code/nel/tools/3d/build_shadow_skin/CMakeLists.txt +++ b/code/nel/tools/3d/build_shadow_skin/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(build_shadow_skin nelmisc nel3d) NL_DEFAULT_PROPS(build_shadow_skin "NeL, Tools, 3D: build_shadow_skin") NL_ADD_RUNTIME_FLAGS(build_shadow_skin) -INSTALL(TARGETS build_shadow_skin RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS build_shadow_skin RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/build_smallbank/CMakeLists.txt b/code/nel/tools/3d/build_smallbank/CMakeLists.txt index 7cfccdaf9..260f6b9aa 100644 --- a/code/nel/tools/3d/build_smallbank/CMakeLists.txt +++ b/code/nel/tools/3d/build_smallbank/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(build_smallbank nel3d nelmisc) NL_DEFAULT_PROPS(build_smallbank "NeL, Tools, 3D: build_smallbank") NL_ADD_RUNTIME_FLAGS(build_smallbank) -INSTALL(TARGETS build_smallbank RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS build_smallbank RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/cluster_viewer/CMakeLists.txt b/code/nel/tools/3d/cluster_viewer/CMakeLists.txt index 98d0c800e..a0db8cd68 100644 --- a/code/nel/tools/3d/cluster_viewer/CMakeLists.txt +++ b/code/nel/tools/3d/cluster_viewer/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(cluster_viewer nel3d nelmisc) NL_DEFAULT_PROPS(cluster_viewer "NeL, Tools, 3D: Cluster Viewer") NL_ADD_RUNTIME_FLAGS(cluster_viewer) -INSTALL(TARGETS cluster_viewer RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS cluster_viewer RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/file_info/CMakeLists.txt b/code/nel/tools/3d/file_info/CMakeLists.txt index ce935c4e4..43cb359fd 100644 --- a/code/nel/tools/3d/file_info/CMakeLists.txt +++ b/code/nel/tools/3d/file_info/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(file_info nel3d nelmisc) NL_DEFAULT_PROPS(file_info "NeL, Tools, 3D: file_info") NL_ADD_RUNTIME_FLAGS(file_info) -INSTALL(TARGETS file_info RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS file_info RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/get_neighbors/CMakeLists.txt b/code/nel/tools/3d/get_neighbors/CMakeLists.txt index 9ed4f6e2c..d8de69ff5 100644 --- a/code/nel/tools/3d/get_neighbors/CMakeLists.txt +++ b/code/nel/tools/3d/get_neighbors/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(get_neighbors nelmisc) NL_DEFAULT_PROPS(get_neighbors "NeL, Tools, 3D: get_neighbors") NL_ADD_RUNTIME_FLAGS(get_neighbors) -INSTALL(TARGETS get_neighbors RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS get_neighbors RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/hls_bank_maker/CMakeLists.txt b/code/nel/tools/3d/hls_bank_maker/CMakeLists.txt index 4b4717087..d2482c276 100644 --- a/code/nel/tools/3d/hls_bank_maker/CMakeLists.txt +++ b/code/nel/tools/3d/hls_bank_maker/CMakeLists.txt @@ -1,11 +1,9 @@ -FILE(GLOB SRC *.cpp *.h ../panoply_maker/hls_bank_texture_info.cpp ../panoply_maker/hls_bank_texture_info.h ../s3tc_compressor_lib/*.cpp ../s3tc_compressor_lib/*.h) +FILE(GLOB SRC *.cpp *.h ../panoply_maker/hls_bank_texture_info.cpp ../panoply_maker/hls_bank_texture_info.h) ADD_EXECUTABLE(hls_bank_maker ${SRC}) -INCLUDE_DIRECTORIES(${SQUISH_INCLUDE_DIR}) - -TARGET_LINK_LIBRARIES(hls_bank_maker ${SQUISH_LIBRARIES} nelmisc nel3d) +TARGET_LINK_LIBRARIES(hls_bank_maker s3tc_compressor nelmisc nel3d) NL_DEFAULT_PROPS(hls_bank_maker "NeL, Tools, 3D: hls_bank_maker") NL_ADD_RUNTIME_FLAGS(hls_bank_maker) -INSTALL(TARGETS hls_bank_maker RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS hls_bank_maker RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/ig_add/CMakeLists.txt b/code/nel/tools/3d/ig_add/CMakeLists.txt index 60f5305c0..2ae993d51 100644 --- a/code/nel/tools/3d/ig_add/CMakeLists.txt +++ b/code/nel/tools/3d/ig_add/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(ig_add nel3d nelmisc) NL_DEFAULT_PROPS(ig_add "NeL, Tools, 3D: ig_add") NL_ADD_RUNTIME_FLAGS(ig_add) -INSTALL(TARGETS ig_add RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS ig_add RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/ig_elevation/CMakeLists.txt b/code/nel/tools/3d/ig_elevation/CMakeLists.txt index e453ed1ce..eb59adf22 100644 --- a/code/nel/tools/3d/ig_elevation/CMakeLists.txt +++ b/code/nel/tools/3d/ig_elevation/CMakeLists.txt @@ -10,4 +10,4 @@ NL_ADD_RUNTIME_FLAGS(ig_elevation) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) -INSTALL(TARGETS ig_elevation RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS ig_elevation RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/ig_info/CMakeLists.txt b/code/nel/tools/3d/ig_info/CMakeLists.txt index bf39e3e16..59f32f9ca 100644 --- a/code/nel/tools/3d/ig_info/CMakeLists.txt +++ b/code/nel/tools/3d/ig_info/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(ig_info nel3d nelmisc) NL_DEFAULT_PROPS(ig_info "NeL, Tools, 3D: ig_info") NL_ADD_RUNTIME_FLAGS(ig_info) -INSTALL(TARGETS ig_info RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS ig_info RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/ig_lighter/CMakeLists.txt b/code/nel/tools/3d/ig_lighter/CMakeLists.txt index 6636329c3..54f703566 100644 --- a/code/nel/tools/3d/ig_lighter/CMakeLists.txt +++ b/code/nel/tools/3d/ig_lighter/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(ig_lighter nelmisc nel3d nelpacs) NL_DEFAULT_PROPS(ig_lighter "NeL, Tools, 3D: ig_lighter") NL_ADD_RUNTIME_FLAGS(ig_lighter) -INSTALL(TARGETS ig_lighter RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS ig_lighter RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/lightmap_optimizer/CMakeLists.txt b/code/nel/tools/3d/lightmap_optimizer/CMakeLists.txt index 0427ba6e4..36e5b2aa4 100644 --- a/code/nel/tools/3d/lightmap_optimizer/CMakeLists.txt +++ b/code/nel/tools/3d/lightmap_optimizer/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(lightmap_optimizer nel3d nelmisc) NL_DEFAULT_PROPS(lightmap_optimizer "NeL, Tools, 3D: lightmap_optimizer") NL_ADD_RUNTIME_FLAGS(lightmap_optimizer) -INSTALL(TARGETS lightmap_optimizer RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS lightmap_optimizer RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/ligo/plugin_max/CMakeLists.txt b/code/nel/tools/3d/ligo/plugin_max/CMakeLists.txt index af00c788a..ddf009188 100644 --- a/code/nel/tools/3d/ligo/plugin_max/CMakeLists.txt +++ b/code/nel/tools/3d/ligo/plugin_max/CMakeLists.txt @@ -22,7 +22,7 @@ NL_ADD_LIB_SUFFIX(ligoscape_utility) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) -INSTALL(TARGETS ligoscape_utility RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +INSTALL(TARGETS ligoscape_utility RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) INSTALL(FILES ligoscript.txt DESTINATION maxplugin/docs) INSTALL(DIRECTORY scripts/ DESTINATION maxplugin/scripts/ diff --git a/code/nel/tools/3d/object_viewer/CMakeLists.txt b/code/nel/tools/3d/object_viewer/CMakeLists.txt index e22e4dc51..f99f49c68 100644 --- a/code/nel/tools/3d/object_viewer/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer/CMakeLists.txt @@ -21,8 +21,8 @@ IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(object_viewer_dll ${CMAKE_CURRENT_SOURCE_DIR}/std_afx.h ${CMAKE_CURRENT_SOURCE_DIR}/std_afx.cpp) ENDIF(WITH_PCH) -INSTALL(TARGETS object_viewer_dll LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) -INSTALL(FILES object_viewer.cfg DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS object_viewer_dll LIBRARY DESTINATION ${NL_LIB_PREFIX} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT tools3d) +INSTALL(FILES object_viewer.cfg DESTINATION ${NL_ETC_PREFIX} COMPONENT tools3d) IF(WITH_MAXPLUGIN) INSTALL(TARGETS object_viewer_dll RUNTIME DESTINATION maxplugin COMPONENT tools3d) INSTALL(FILES object_viewer.cfg DESTINATION maxplugin COMPONENT tools3d) diff --git a/code/nel/tools/3d/object_viewer_exe/CMakeLists.txt b/code/nel/tools/3d/object_viewer_exe/CMakeLists.txt index 605030308..d6adb9694 100644 --- a/code/nel/tools/3d/object_viewer_exe/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_exe/CMakeLists.txt @@ -19,7 +19,7 @@ IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(object_viewer ${CMAKE_CURRENT_SOURCE_DIR}/std_afx.h ${CMAKE_CURRENT_SOURCE_DIR}/std_afx.cpp) ENDIF(WITH_PCH) -INSTALL(TARGETS object_viewer RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS object_viewer RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) IF(WITH_MAXPLUGIN) INSTALL(TARGETS object_viewer RUNTIME DESTINATION maxplugin COMPONENT tools3d) ENDIF(WITH_MAXPLUGIN) diff --git a/code/nel/tools/3d/object_viewer_qt/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/CMakeLists.txt index 9e54a1857..ff1128b9f 100644 --- a/code/nel/tools/3d/object_viewer_qt/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/CMakeLists.txt @@ -5,8 +5,26 @@ # #----------------------------------------------------------------------------- -# This tells the application(s) where to fidn the installed data. -ADD_DEFINITIONS(-DDATA_DIR="\\"${NL_SHARE_PREFIX}/object_viewer_qt/\\"") +# This tells the application(s) where to find the installed data. +IF(WIN32) + SET(OVQT_PLUGIN_SPECS_DIR "plugins") + SET(OVQT_PLUGIN_DIR "plugins") + SET(OVQT_DATA_DIR ".") +ELSEIF(APPLE) + # TODO: under Mac OS X, don't install but copy files in application package + SET(OVQT_PLUGIN_SPECS_DIR "plugins") + SET(OVQT_PLUGIN_DIR "plugins") + SET(OVQT_DATA_DIR ".") +ELSE(WIN32) + SET(OVQT_PLUGIN_SPECS_DIR ${NL_SHARE_PREFIX}/object_viewer_qt/plugins) + SET(OVQT_PLUGIN_DIR ${NL_LIB_PREFIX}/object_viewer_qt) + SET(OVQT_DATA_DIR ${NL_SHARE_PREFIX}/object_viewer_qt/data) + + CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/ovqt_config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/ovqt_config.h) + INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}) + + ADD_DEFINITIONS(-DHAVE_OVQT_CONFIG_H) +ENDIF(WIN32) IF(UNIX AND WITH_STATIC) MESSAGE(FATAL_ERROR "OVQT does not work with static NeL builds on Unix atm.") @@ -15,7 +33,7 @@ ENDIF() ADD_SUBDIRECTORY(src) INSTALL(DIRECTORY data/ - DESTINATION share/object_viewer_qt/data + DESTINATION ${OVQT_DATA_DIR} COMPONENT data PATTERN "CVS" EXCLUDE PATTERN ".svn" EXCLUDE diff --git a/code/nel/tools/3d/object_viewer_qt/ovqt_config.h.cmake b/code/nel/tools/3d/object_viewer_qt/ovqt_config.h.cmake new file mode 100644 index 000000000..5b3a49654 --- /dev/null +++ b/code/nel/tools/3d/object_viewer_qt/ovqt_config.h.cmake @@ -0,0 +1,7 @@ +#ifndef OVQT_CONFIG_H +#define OVQT_CONFIG_H + +#define DATA_DIR "${NL_SHARE_ABSOLUTE_PREFIX}/object_viewer_qt" +#define PLUGINS_DIR "${NL_LIB_ABSOLUTE_PREFIX}/object_viewer_qt" + +#endif diff --git a/code/nel/tools/3d/object_viewer_qt/src/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/CMakeLists.txt index 7dc1445bb..d77b0e6a1 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/CMakeLists.txt @@ -21,12 +21,12 @@ SET(OBJECT_VIEWER_TS translations/object_viewer_qt_en.ts SET(QT_USE_QTGUI TRUE) SET(QT_USE_QTOPENGL TRUE) - -IF(WIN32) - SET(OBJECT_VIEWER_RC object_viewer_qt.rc) + +IF(WIN32) + SET(OBJECT_VIEWER_RC object_viewer_qt.rc) ENDIF(WIN32) -QT4_ADD_TRANSLATION(OBJECT_VIEWER_QM ${OBJECT_VIEWER_TS}) +QT4_ADD_TRANSLATION(OBJECT_VIEWER_QM ${OBJECT_VIEWER_TS}) QT4_ADD_RESOURCES( OBJECT_VIEWER_RC_SRCS ${OBJECT_VIEWER_RCS}) QT4_WRAP_CPP( OBJECT_VIEWER_MOC_SRCS ${OBJECT_VIEWER_HDR} ) @@ -50,4 +50,4 @@ NL_ADD_RUNTIME_FLAGS(object_viewer_qt) ADD_SUBDIRECTORY(plugins) -INSTALL(TARGETS object_viewer_qt RUNTIME DESTINATION bin COMPONENT runtime BUNDLE DESTINATION /Applications) +INSTALL(TARGETS object_viewer_qt RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT runtime BUNDLE DESTINATION /Applications) diff --git a/code/nel/tools/3d/object_viewer_qt/src/extension_system/plugin_spec.cpp b/code/nel/tools/3d/object_viewer_qt/src/extension_system/plugin_spec.cpp index 30e35f8c1..fea606af2 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/extension_system/plugin_spec.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/extension_system/plugin_spec.cpp @@ -31,6 +31,14 @@ #include #include +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#ifdef HAVE_OVQT_CONFIG_H +#include "ovqt_config.h" +#endif + namespace ExtensionSystem { const char *const PLUGIN_SPEC_NAME = "name"; @@ -71,6 +79,7 @@ PluginSpec::PluginSpec() # error "Unknown compilation mode, can't build suffix" # endif #elif defined (NL_OS_UNIX) + m_prefix = "lib"; m_suffix = ".so"; #else # error "You must define the lib suffix for your platform" @@ -139,12 +148,47 @@ QList PluginSpec::dependencySpecs() const bool PluginSpec::setFileName(const QString &fileName) { - m_fileName = fileName + m_suffix; + m_fileName = m_prefix + fileName + m_suffix; m_filePath = m_location + "/" + m_fileName; + QFile file; + file.setFileName(m_filePath); + + bool exists = file.exists(); + +#ifdef NL_OS_UNIX + +#ifdef PLUGINS_DIR + if (!exists) + { + // if plugin can't be found in the same directory as spec file, + // looks for it in PLUGINS_DIR + m_filePath = QString("%1/%2").arg(PLUGINS_DIR).arg(m_fileName); + + file.setFileName(m_filePath); + + exists = file.exists(); + } +#endif + +#ifdef NL_LIB_PREFIX + if (!exists) + { + // if plugin can't be found in the same directory as spec file or PLUGINS_DIR, + // looks for it in NL_LIB_PREFIX + m_filePath = QString("%1/%2").arg(NL_LIB_PREFIX).arg(m_fileName); + + file.setFileName(m_filePath); + + exists = file.exists(); + } +#endif + +#endif + nlinfo(m_filePath.toStdString().c_str()); - QFile file(m_filePath); - if (!file.exists()) + + if (!exists) return reportError(QCoreApplication::translate("PluginSpec", "File does not exist: %1").arg(file.fileName())); if (!file.open(QIODevice::ReadOnly)) return reportError(QCoreApplication::translate("PluginSpec", "Could not open file for read: %1").arg(file.fileName())); @@ -390,4 +434,4 @@ bool PluginSpec::reportError(const QString &err) return false; } -} // namespace ExtensionSystem \ No newline at end of file +} // namespace ExtensionSystem diff --git a/code/nel/tools/3d/object_viewer_qt/src/extension_system/plugin_spec.h b/code/nel/tools/3d/object_viewer_qt/src/extension_system/plugin_spec.h index c28980d69..0ce74d004 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/extension_system/plugin_spec.h +++ b/code/nel/tools/3d/object_viewer_qt/src/extension_system/plugin_spec.h @@ -84,6 +84,7 @@ private: QString m_description; QString m_nameSpecFile; + QString m_prefix; QString m_suffix; int m_state; bool m_enabled, m_enabledStartup; diff --git a/code/nel/tools/3d/object_viewer_qt/src/main.cpp b/code/nel/tools/3d/object_viewer_qt/src/main.cpp index 7e9e05a77..ea78905fa 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/main.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/main.cpp @@ -41,6 +41,10 @@ #include #include +#ifdef HAVE_OVQT_CONFIG_H +#include "ovqt_config.h" +#endif + static const char *appNameC = "ObjectViewerQt"; // nel_qt log file name @@ -151,10 +155,10 @@ sint main(int argc, char **argv) ExtensionSystem::PluginManager pluginManager; pluginManager.setSettings(settings); QStringList pluginPaths; -#if !defined(NL_OS_MAC) - pluginPaths << settings->value("PluginPath", "./plugins").toString(); -#else +#if defined(NL_OS_MAC) pluginPaths << settings->value("PluginPath", qApp->applicationDirPath() + QString("/../PlugIns/ovqt")).toString(); +#else + pluginPaths << settings->value("PluginPath", QString("%1/plugins").arg(DATA_DIR)).toString(); #endif pluginManager.setPluginPaths(pluginPaths); @@ -198,4 +202,4 @@ sint main(int argc, char **argv) int result = app.exec(); return result; -} \ No newline at end of file +} diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/bnp_manager/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/bnp_manager/CMakeLists.txt index 08adfb89c..2991da073 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/bnp_manager/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/bnp_manager/CMakeLists.txt @@ -44,4 +44,6 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_bnp_manager) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_bnp_manager LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +INSTALL(TARGETS ovqt_plugin_bnp_manager LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_bnp_manager.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/core/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/core/CMakeLists.txt index 77f3562e6..17172c488 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/core/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/core/CMakeLists.txt @@ -55,4 +55,19 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_core) ADD_DEFINITIONS(-DCORE_LIBRARY ${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_core LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +IF(WIN32) + IF(WITH_INSTALL_LIBRARIES) + INSTALL(TARGETS ovqt_plugin_core LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} RUNTIME DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) + ELSE(WITH_INSTALL_LIBRARIES) + INSTALL(TARGETS ovqt_plugin_core LIBRARY DESTINATION ${NL_LIB_PREFIX} RUNTIME DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) + ENDIF(WITH_INSTALL_LIBRARIES) +ELSE(WIN32) + IF(WITH_INSTALL_LIBRARIES) + INSTALL(TARGETS ovqt_plugin_core LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) + ELSE(WITH_INSTALL_LIBRARIES) + INSTALL(TARGETS ovqt_plugin_core LIBRARY DESTINATION ${NL_LIB_PREFIX} RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) + ENDIF(WITH_INSTALL_LIBRARIES) +ENDIF(WIN32) + +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_core.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/core/general_settings_page.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/core/general_settings_page.cpp index 9031fcb9f..e21edafec 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/core/general_settings_page.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/core/general_settings_page.cpp @@ -31,6 +31,10 @@ #include #include +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + namespace Core { @@ -83,11 +87,18 @@ void GeneralSettingsPage::applyGeneralSettings() QApplication::setPalette(m_originalPalette); settings->endGroup(); + QString levelDesignPrefix; +#if defined(_DEBUG) && defined(NL_OS_WINDOWS) + levelDesignPrefix = "l:"; +#else + levelDesignPrefix = QString("%1/data_leveldesign").arg(RYZOM_SHARE_PREFIX); +#endif + // Add primitives path and ligo config file to CPath settings->beginGroup(Core::Constants::DATA_PATH_SECTION); - QString primitivePath = settings->value(Core::Constants::PRIMITIVES_PATH, "l:/primitives").toString(); - QString ligoConfigFile = settings->value(Core::Constants::LIGOCONFIG_FILE, "l:/leveldesign/world_editor_files/world_editor_classes.xml").toString(); - QString leveldesignPath = settings->value(Core::Constants::LEVELDESIGN_PATH, "l:/leveldesign").toString(); + QString primitivePath = settings->value(Core::Constants::PRIMITIVES_PATH, QString("%1/primitives").arg(levelDesignPrefix)).toString(); + QString ligoConfigFile = settings->value(Core::Constants::LIGOCONFIG_FILE, QString("%1/leveldesign/world_editor_files/world_editor_classes.xml").arg(levelDesignPrefix)).toString(); + QString leveldesignPath = settings->value(Core::Constants::LEVELDESIGN_PATH, QString("%1/leveldesign").arg(levelDesignPrefix)).toString(); NLMISC::CPath::addSearchPath(primitivePath.toStdString(), true, false); NLMISC::CPath::display(); NLMISC::CPath::addSearchFile(ligoConfigFile.toStdString()); diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/disp_sheet_id/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/disp_sheet_id/CMakeLists.txt index 790af3ef6..f7bb49daf 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/disp_sheet_id/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/disp_sheet_id/CMakeLists.txt @@ -40,4 +40,6 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_disp_sheet_id) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_disp_sheet_id LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) \ No newline at end of file +INSTALL(TARGETS ovqt_plugin_disp_sheet_id LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_disp_sheet_id.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/example/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/example/CMakeLists.txt index f34309a74..4b24a0363 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/example/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/example/CMakeLists.txt @@ -38,4 +38,6 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_example) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_example LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +INSTALL(TARGETS ovqt_plugin_example LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_example.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/example/qnel_widget.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/example/qnel_widget.cpp index 4872923db..d512521f7 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/example/qnel_widget.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/example/qnel_widget.cpp @@ -60,7 +60,7 @@ QNLWidget::~QNLWidget() void QNLWidget::init() { // create the driver - m_driver = NL3D::UDriver::createDriver(NULL, false, NULL); + m_driver = NL3D::UDriver::createDriver(0, false); nlassert(m_driver); // initialize the nel 3d viewport diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/CMakeLists.txt index 3661decef..514657535 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/georges_editor/CMakeLists.txt @@ -44,4 +44,6 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_georges_editor) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_georges_editor LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +INSTALL(TARGETS ovqt_plugin_georges_editor LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_georges_editor.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/landscape_editor/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/landscape_editor/CMakeLists.txt index c7450586e..dc7a8a541 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/landscape_editor/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/landscape_editor/CMakeLists.txt @@ -45,4 +45,6 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_landscape_editor) ADD_DEFINITIONS(-DLANDSCAPE_EDITOR_LIBRARY ${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_landscape_editor LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +INSTALL(TARGETS ovqt_plugin_landscape_editor LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +#INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_landscape_editor.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/log/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/log/CMakeLists.txt index 31569ae6b..1e0511a1c 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/log/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/log/CMakeLists.txt @@ -36,4 +36,6 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_log) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_log LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +INSTALL(TARGETS ovqt_plugin_log LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_log.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/mission_compiler/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/mission_compiler/CMakeLists.txt index ac262ad56..03f1a6a2f 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/mission_compiler/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/mission_compiler/CMakeLists.txt @@ -46,4 +46,6 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_mission_compiler) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_mission_compiler LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +INSTALL(TARGETS ovqt_plugin_mission_compiler LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_mission_compiler.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/mission_compiler/mission_compiler_main_window.cpp b/code/nel/tools/3d/object_viewer_qt/src/plugins/mission_compiler/mission_compiler_main_window.cpp index 9a3f4fe61..0c791aa7c 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/mission_compiler/mission_compiler_main_window.cpp +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/mission_compiler/mission_compiler_main_window.cpp @@ -381,7 +381,7 @@ bool MissionCompilerMainWindow::parsePrimForMissions(NLLIGO::IPrimitive const *p { std::string value; // if the node is a mission parse it - if (prim->getPropertyByName("class",value) && !NLMISC::stricmp(value.c_str(),"mission") ) + if (prim->getPropertyByName("class",value) && !NLMISC::nlstricmp(value.c_str(),"mission") ) { std::string name; prim->getPropertyByName("name",name); diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/CMakeLists.txt index 7f084fbb1..b5af7f1e9 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/object_viewer/CMakeLists.txt @@ -1,166 +1,168 @@ -INCLUDE_DIRECTORIES( ${CMAKE_CURRENT_BINARY_DIR} - ${CMAKE_CURRENT_SOURCE_DIR} - ${LIBXML2_INCLUDE_DIR} - ${QT_INCLUDES}) - -FILE(GLOB SRC *.cpp *.h) - -SET(OVQT_EXT_SYS_SRC ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin.h - ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin_manager.h - ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin_spec.h) - -SET(OBJECT_VIEWER_PLUGIN_HDR object_viewer_plugin.h - main_window.h - graphics_viewport.h - animation_dialog.h - animation_set_dialog.h - setup_fog_dialog.h - slot_manager_dialog.h - particle_control_dialog.h - particle_workspace_dialog.h - particle_tree_model.h - particle_system_page.h - particle_workspace_page.h - edit_range_widget.h - emitter_page.h - attrib_widget.h - located_bindable_page.h - located_page.h - particle_force_page.h - particle_light_page.h - particle_zone_page.h - particle_sound_page.h - basic_edit_widget.h - direction_widget.h - color_edit_widget.h - particle_property_dialog.h - ps_mover_page.h - value_blender_dialog.h - value_gradient_dialog.h - value_from_emitter_dialog.h - curve_dialog.h - bin_op_dialog.h - hoverpoints.h - mesh_widget.h - morph_mesh_dialog.h - constraint_mesh_widget.h - tail_particle_widget.h - auto_lod_dialog.h - particle_texture_widget.h - particle_texture_anim_widget.h - multi_tex_dialog.h - spinner_dialog.h - follow_path_dialog.h - water_pool_dialog.h - skeleton_scale_dialog.h - skeleton_tree_model.h - particle_link_skeleton_dialog.h - vegetable_dialog.h - global_wind_dialog.h - day_night_dialog.h - sun_color_dialog.h - vegetable_noise_value_widget.h - vegetable_density_page.h - vegetable_landscape_page.h - vegetable_scale_page.h - vegetable_appearance_page.h - vegetable_rotate_page.h - tune_mrm_dialog.h - tune_timer_dialog.h - camera_control.h - graphics_settings_page.h - sound_settings_page.h - vegetable_settings_page.h - scheme_bank_dialog.h) - -SET(OBJECT_VIEWER_PLUGIN_UIS animation_form.ui - animation_set_form.ui - setup_fog_form.ui - slot_form.ui - particle_control_form.ui - particle_workspace_form.ui - edit_range_float_form.ui - edit_range_uint_form.ui - particle_system_form.ui - workspace_form.ui - attrib_form.ui - emitter_form.ui - located_bindable_form.ui - located_form.ui - particle_force_form.ui - particle_light_form.ui - particle_zone_form.ui - particle_sound_form.ui - basic_edit_form.ui - direction_form.ui - color_edit_form.ui - ps_mover_form.ui - curve_form.ui - mesh_form.ui - morph_mesh_form.ui - constraint_mesh_form.ui - tail_form.ui - auto_lod_form.ui - particle_texture_form.ui - particle_texture_anim_form.ui - multi_tex_form.ui - skeleton_scale_form.ui - particle_link_skeleton_form.ui - water_pool_form.ui - vegetable_dialog_form.ui - vegetable_noise_value_form.ui - global_wind_form.ui - sun_color_form.ui - day_night_form.ui - vegetable_density_form.ui - vegetable_apperance_form.ui - vegetable_landscape_form.ui - vegetable_rotate_form.ui - vegetable_scale_form.ui - tune_mrm_form.ui - tune_timer_form.ui - graphics_settings_page.ui - sound_settings_page.ui - vegetable_settings_page.ui - scheme_bank_form.ui - value_gradient_form.ui) - -SET(OBJECT_VIEWER_PLUGIN_RCS object_viewer.qrc) - -SET(QT_USE_QTGUI TRUE) -SET(QT_USE_QTOPENGL TRUE) - -QT4_ADD_RESOURCES(OBJECT_VIEWER_PLUGIN_RC_SRCS ${OBJECT_VIEWER_PLUGIN_RCS}) -QT4_WRAP_CPP(OBJECT_VIEWER_PLUGIN_MOC_SRC ${OBJECT_VIEWER_PLUGIN_HDR}) -QT4_WRAP_UI(OBJECT_VIEWER_PLUGIN_UI_HDRS ${OBJECT_VIEWER_PLUGIN_UIS}) - -SOURCE_GROUP(QtResources FILES ${OBJECT_VIEWER_PLUGIN_UIS}) -SOURCE_GROUP(QtGeneratedUiHdr FILES ${OBJECT_VIEWER_PLUGIN_UI_HDRS}) -SOURCE_GROUP(QtGeneratedMocSrc FILES ${OBJECT_VIEWER_PLUGIN_MOC_SRC}) -SOURCE_GROUP("Object Viewer Plugin" FILES ${SRC}) -SOURCE_GROUP("OVQT Extension System" FILES ${OVQT_EXT_SYS_SRC}) - -ADD_LIBRARY(ovqt_plugin_object_viewer MODULE ${SRC} ${OBJECT_VIEWER_PLUGIN_MOC_SRC} ${OVQT_EXT_SYS_SRC} ${OBJECT_VIEWER_PLUGIN_UI_HDRS} ${OBJECT_VIEWER_PLUGIN_RC_SRCS}) - -TARGET_LINK_LIBRARIES(ovqt_plugin_object_viewer - ovqt_plugin_core - nelmisc - nel3d - nelsound - nelligo - nelgeorges - ${QT_LIBRARIES} - ${QT_QTOPENGL_LIBRARY}) - -NL_DEFAULT_PROPS(ovqt_plugin_object_viewer "NeL, Tools, 3D: Object Viewer Qt Plugin: Object Viewer") - +INCLUDE_DIRECTORIES( ${CMAKE_CURRENT_BINARY_DIR} + ${CMAKE_CURRENT_SOURCE_DIR} + ${LIBXML2_INCLUDE_DIR} + ${QT_INCLUDES}) + +FILE(GLOB SRC *.cpp *.h) + +SET(OVQT_EXT_SYS_SRC ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin.h + ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin_manager.h + ${CMAKE_CURRENT_SOURCE_DIR}/../../extension_system/iplugin_spec.h) + +SET(OBJECT_VIEWER_PLUGIN_HDR object_viewer_plugin.h + main_window.h + graphics_viewport.h + animation_dialog.h + animation_set_dialog.h + setup_fog_dialog.h + slot_manager_dialog.h + particle_control_dialog.h + particle_workspace_dialog.h + particle_tree_model.h + particle_system_page.h + particle_workspace_page.h + edit_range_widget.h + emitter_page.h + attrib_widget.h + located_bindable_page.h + located_page.h + particle_force_page.h + particle_light_page.h + particle_zone_page.h + particle_sound_page.h + basic_edit_widget.h + direction_widget.h + color_edit_widget.h + particle_property_dialog.h + ps_mover_page.h + value_blender_dialog.h + value_gradient_dialog.h + value_from_emitter_dialog.h + curve_dialog.h + bin_op_dialog.h + hoverpoints.h + mesh_widget.h + morph_mesh_dialog.h + constraint_mesh_widget.h + tail_particle_widget.h + auto_lod_dialog.h + particle_texture_widget.h + particle_texture_anim_widget.h + multi_tex_dialog.h + spinner_dialog.h + follow_path_dialog.h + water_pool_dialog.h + skeleton_scale_dialog.h + skeleton_tree_model.h + particle_link_skeleton_dialog.h + vegetable_dialog.h + global_wind_dialog.h + day_night_dialog.h + sun_color_dialog.h + vegetable_noise_value_widget.h + vegetable_density_page.h + vegetable_landscape_page.h + vegetable_scale_page.h + vegetable_appearance_page.h + vegetable_rotate_page.h + tune_mrm_dialog.h + tune_timer_dialog.h + camera_control.h + graphics_settings_page.h + sound_settings_page.h + vegetable_settings_page.h + scheme_bank_dialog.h) + +SET(OBJECT_VIEWER_PLUGIN_UIS animation_form.ui + animation_set_form.ui + setup_fog_form.ui + slot_form.ui + particle_control_form.ui + particle_workspace_form.ui + edit_range_float_form.ui + edit_range_uint_form.ui + particle_system_form.ui + workspace_form.ui + attrib_form.ui + emitter_form.ui + located_bindable_form.ui + located_form.ui + particle_force_form.ui + particle_light_form.ui + particle_zone_form.ui + particle_sound_form.ui + basic_edit_form.ui + direction_form.ui + color_edit_form.ui + ps_mover_form.ui + curve_form.ui + mesh_form.ui + morph_mesh_form.ui + constraint_mesh_form.ui + tail_form.ui + auto_lod_form.ui + particle_texture_form.ui + particle_texture_anim_form.ui + multi_tex_form.ui + skeleton_scale_form.ui + particle_link_skeleton_form.ui + water_pool_form.ui + vegetable_dialog_form.ui + vegetable_noise_value_form.ui + global_wind_form.ui + sun_color_form.ui + day_night_form.ui + vegetable_density_form.ui + vegetable_apperance_form.ui + vegetable_landscape_form.ui + vegetable_rotate_form.ui + vegetable_scale_form.ui + tune_mrm_form.ui + tune_timer_form.ui + graphics_settings_page.ui + sound_settings_page.ui + vegetable_settings_page.ui + scheme_bank_form.ui + value_gradient_form.ui) + +SET(OBJECT_VIEWER_PLUGIN_RCS object_viewer.qrc) + +SET(QT_USE_QTGUI TRUE) +SET(QT_USE_QTOPENGL TRUE) + +QT4_ADD_RESOURCES(OBJECT_VIEWER_PLUGIN_RC_SRCS ${OBJECT_VIEWER_PLUGIN_RCS}) +QT4_WRAP_CPP(OBJECT_VIEWER_PLUGIN_MOC_SRC ${OBJECT_VIEWER_PLUGIN_HDR}) +QT4_WRAP_UI(OBJECT_VIEWER_PLUGIN_UI_HDRS ${OBJECT_VIEWER_PLUGIN_UIS}) + +SOURCE_GROUP(QtResources FILES ${OBJECT_VIEWER_PLUGIN_UIS}) +SOURCE_GROUP(QtGeneratedUiHdr FILES ${OBJECT_VIEWER_PLUGIN_UI_HDRS}) +SOURCE_GROUP(QtGeneratedMocSrc FILES ${OBJECT_VIEWER_PLUGIN_MOC_SRC}) +SOURCE_GROUP("Object Viewer Plugin" FILES ${SRC}) +SOURCE_GROUP("OVQT Extension System" FILES ${OVQT_EXT_SYS_SRC}) + +ADD_LIBRARY(ovqt_plugin_object_viewer MODULE ${SRC} ${OBJECT_VIEWER_PLUGIN_MOC_SRC} ${OVQT_EXT_SYS_SRC} ${OBJECT_VIEWER_PLUGIN_UI_HDRS} ${OBJECT_VIEWER_PLUGIN_RC_SRCS}) + +TARGET_LINK_LIBRARIES(ovqt_plugin_object_viewer + ovqt_plugin_core + nelmisc + nel3d + nelsound + nelligo + nelgeorges + ${QT_LIBRARIES} + ${QT_QTOPENGL_LIBRARY}) + +NL_DEFAULT_PROPS(ovqt_plugin_object_viewer "NeL, Tools, 3D: Object Viewer Qt Plugin: Object Viewer") + IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(ovqt_plugin_object_viewer ${CMAKE_CURRENT_SOURCE_DIR}/stdpch.h ${CMAKE_CURRENT_SOURCE_DIR}/stdpch.cpp) -ENDIF(WITH_PCH) - -NL_ADD_RUNTIME_FLAGS(ovqt_plugin_object_viewer) -NL_ADD_LIB_SUFFIX(ovqt_plugin_object_viewer) - -ADD_DEFINITIONS(-DQT_NO_KEYWORDS ${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) - -INSTALL(TARGETS ovqt_plugin_object_viewer LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +ENDIF(WITH_PCH) + +NL_ADD_RUNTIME_FLAGS(ovqt_plugin_object_viewer) +NL_ADD_LIB_SUFFIX(ovqt_plugin_object_viewer) + +ADD_DEFINITIONS(-DQT_NO_KEYWORDS ${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) + +INSTALL(TARGETS ovqt_plugin_object_viewer LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_object_viewer.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/ovqt_sheet_builder/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/ovqt_sheet_builder/CMakeLists.txt index 2d4ddaa9d..52965a3d4 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/ovqt_sheet_builder/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/ovqt_sheet_builder/CMakeLists.txt @@ -29,4 +29,6 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_sheet_builder) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_sheet_builder LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +INSTALL(TARGETS ovqt_plugin_sheet_builder LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_sheet_builder.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/translation_manager/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/translation_manager/CMakeLists.txt index 505340487..a7de55dfb 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/translation_manager/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/translation_manager/CMakeLists.txt @@ -48,4 +48,6 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_translation_manager) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_translation_manager LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +INSTALL(TARGETS ovqt_plugin_translation_manager LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_translation_manager.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/plugins/zone_painter/CMakeLists.txt b/code/nel/tools/3d/object_viewer_qt/src/plugins/zone_painter/CMakeLists.txt index 2ddbe868e..e9023c4b9 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/plugins/zone_painter/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_qt/src/plugins/zone_painter/CMakeLists.txt @@ -42,4 +42,6 @@ NL_ADD_LIB_SUFFIX(ovqt_plugin_zone_painter) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DQT_PLUGIN -DQT_SHARED ${QT_DEFINITIONS}) -INSTALL(TARGETS ovqt_plugin_zone_painter LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT tools3d) +INSTALL(TARGETS ovqt_plugin_zone_painter LIBRARY DESTINATION ${OVQT_PLUGIN_DIR} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${OVQT_PLUGIN_DIR} COMPONENT tools3d) +INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/ovqt_plugin_zone_painter.xml DESTINATION ${OVQT_PLUGIN_SPECS_DIR} COMPONENT tools3d) + diff --git a/code/nel/tools/3d/object_viewer_qt/src/translations/object_viewer_qt_fr.ts b/code/nel/tools/3d/object_viewer_qt/src/translations/object_viewer_qt_fr.ts index d980a0914..f5c0c68af 100644 --- a/code/nel/tools/3d/object_viewer_qt/src/translations/object_viewer_qt_fr.ts +++ b/code/nel/tools/3d/object_viewer_qt/src/translations/object_viewer_qt_fr.ts @@ -6,17 +6,17 @@ Failed to load Core plugin: %1 - + Impossible de charger le plugin principal: %1 Object Viewer Qt - Plugin loader messages - + Object Viewer Qt - Messages du chargeur de plugins Could not find ovqt_plugin_core in %1 - + Impossible de trouver ovqt_plugin_core dans %1 @@ -24,42 +24,42 @@ Animation control - + Contrôle de l'animation Loop - + En boucle In place - + En place Increment pos - + Incrémenter la position Use the PlayList - + Utiliser la liste de lecture Use the Mixer - + Utilisateur le Mélangeur Play/Pause - + Lecture/Pause Stop - + Stop @@ -67,57 +67,57 @@ Animation set manager - + Gestionnaire d'ensemble d'animations Edited object: - + Objet en cours d'édition : Animations: - + Animations : Add anim - + Ajouter animation Skeleton weight template: - + Modèle de poids de squelette : Add swt - + Ajouter swt Animations playlist: - + Liste de lecture d'animations : Unload all anim and swt files - + Décharger toutes les animations et les fichiers swt Add anim in PlayList - + Ajouter une animation dans la liste de lecture Delete anim from PlayList - + Supprimer une animation de la liste de lecture Set duration of time in Animation control - + Définir la durée dans le contrôle de l'animation @@ -130,7 +130,7 @@ Constant - + Constante @@ -160,12 +160,12 @@ Date - + Date Position - + Position @@ -175,12 +175,12 @@ Speed - + Vitesse Random - + Aléatoire @@ -2593,7 +2593,7 @@ Power: - + Puissance : @@ -2603,17 +2603,17 @@ Frequency - + Fréquence Ambient color - + Couleur ambiante Diffuse color - + Couleur diffuse @@ -3119,67 +3119,67 @@ Reason: %3 OpenGL - + OpenGL Direct3D - + Direct3D Qt Style - + Style Qt Style - + Style Use style's standard palette - + Utiliser la palette standard du style Font - + Police ... - + ... Graphics settings - + Options graphiques Driver - + Pilote Bloom effect - + Bloom Bloom density - + Densité du bloom Square bloom - + Bloom carré Enable bloom effect - + Activer le bloom @@ -3188,17 +3188,17 @@ Reason: %3 Open NeL anim file - + Ouvrir une animation NeL NeL anim files (*.anim);; - + Animations NeL (*.anim);; NeL Skeleton Weight Template files (*.swt);; - + NeL Skeleton Weight Template (*.swt);; @@ -3336,7 +3336,7 @@ Reason: %3 Set user param - + Définir un paramètre utilisateur @@ -3344,7 +3344,7 @@ Reason: %3 Bin operator - + Opérateur binaire @@ -3556,7 +3556,7 @@ Reason: %3 Num samples: - + Nombre d'échantillons : @@ -3801,17 +3801,17 @@ Reason: %3 Num particles: - + Nombre de particules : Num wanted faces: - + Nombre de faces souhaitées : System time: - + Temps système : @@ -3819,7 +3819,7 @@ Reason: %3 Are you sure? - + Etes-vous sûr ? @@ -4077,7 +4077,7 @@ Reason: %3 Skeleton scale editor - + Editeur de l'échelle du squelette @@ -4121,12 +4121,12 @@ Reason: %3 Failed to save file! - + Impossible d'enregistrer le fichier ! Failed to load file! - + Impossible de charger le fichier ! @@ -4142,7 +4142,7 @@ Reason: %3 empty - + vide diff --git a/code/nel/tools/3d/object_viewer_widget/CMakeLists.txt b/code/nel/tools/3d/object_viewer_widget/CMakeLists.txt index 4967e8206..20e5b69e8 100644 --- a/code/nel/tools/3d/object_viewer_widget/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_widget/CMakeLists.txt @@ -6,7 +6,7 @@ #----------------------------------------------------------------------------- # This tells the application(s) where to find the installed data. -#ADD_DEFINITIONS(-DDATA_DIR="\\"${NL_SHARE_PREFIX}/georges_editor_qt/\\"") +#ADD_DEFINITIONS(-DDATA_DIR="\\"${NL_SHARE_ABSOLUTE_PREFIX}/georges_editor_qt/\\"") ADD_SUBDIRECTORY(src) diff --git a/code/nel/tools/3d/object_viewer_widget/src/CMakeLists.txt b/code/nel/tools/3d/object_viewer_widget/src/CMakeLists.txt index 160aca337..0943f61fa 100644 --- a/code/nel/tools/3d/object_viewer_widget/src/CMakeLists.txt +++ b/code/nel/tools/3d/object_viewer_widget/src/CMakeLists.txt @@ -39,4 +39,4 @@ IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(object_viewer_widget_qt ${CMAKE_CURRENT_SOURCE_DIR}/stdpch.h ${CMAKE_CURRENT_SOURCE_DIR}/stdpch.cpp) ENDIF(WITH_PCH) -#INSTALL(TARGETS object_viewer_widget_qt RUNTIME DESTINATION bin COMPONENT runtime BUNDLE DESTINATION /Applications) +#INSTALL(TARGETS object_viewer_widget_qt RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT runtime BUNDLE DESTINATION /Applications) diff --git a/code/nel/tools/3d/panoply_maker/CMakeLists.txt b/code/nel/tools/3d/panoply_maker/CMakeLists.txt index 4a39ab154..8fd25fef6 100644 --- a/code/nel/tools/3d/panoply_maker/CMakeLists.txt +++ b/code/nel/tools/3d/panoply_maker/CMakeLists.txt @@ -1,11 +1,9 @@ -FILE(GLOB SRC *.cpp *.h ../s3tc_compressor_lib/*.h ../s3tc_compressor_lib/*.cpp) +FILE(GLOB SRC *.cpp *.h) ADD_EXECUTABLE(panoply_maker ${SRC}) -INCLUDE_DIRECTORIES(${SQUISH_INCLUDE_DIR}) - -TARGET_LINK_LIBRARIES(panoply_maker ${SQUISH_LIBRARIES} nelmisc nel3d) +TARGET_LINK_LIBRARIES(panoply_maker s3tc_compressor nelmisc nel3d) NL_DEFAULT_PROPS(panoply_maker "NeL, Tools, 3D: panoply_maker") NL_ADD_RUNTIME_FLAGS(panoply_maker) -INSTALL(TARGETS panoply_maker RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS panoply_maker RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/plugin_max/nel_3dsmax_shared/CMakeLists.txt b/code/nel/tools/3d/plugin_max/nel_3dsmax_shared/CMakeLists.txt index 7233f2f76..3a596badc 100644 --- a/code/nel/tools/3d/plugin_max/nel_3dsmax_shared/CMakeLists.txt +++ b/code/nel/tools/3d/plugin_max/nel_3dsmax_shared/CMakeLists.txt @@ -22,4 +22,4 @@ IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(nel_3dsmax_shared ${CMAKE_CURRENT_SOURCE_DIR}/StdAfx.h ${CMAKE_CURRENT_SOURCE_DIR}/StdAfx.cpp) ENDIF(WITH_PCH) -INSTALL(TARGETS nel_3dsmax_shared RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +INSTALL(TARGETS nel_3dsmax_shared RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) diff --git a/code/nel/tools/3d/plugin_max/nel_export/CMakeLists.txt b/code/nel/tools/3d/plugin_max/nel_export/CMakeLists.txt index 32bac9067..93ae28370 100644 --- a/code/nel/tools/3d/plugin_max/nel_export/CMakeLists.txt +++ b/code/nel/tools/3d/plugin_max/nel_export/CMakeLists.txt @@ -31,4 +31,4 @@ IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(nel_export ${CMAKE_CURRENT_SOURCE_DIR}/std_afx.h ${CMAKE_CURRENT_SOURCE_DIR}/std_afx.cpp) ENDIF(WITH_PCH) -INSTALL(TARGETS nel_export RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +INSTALL(TARGETS nel_export RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) diff --git a/code/nel/tools/3d/plugin_max/nel_mesh_lib/CMakeLists.txt b/code/nel/tools/3d/plugin_max/nel_mesh_lib/CMakeLists.txt index 555edd263..a6161338d 100644 --- a/code/nel/tools/3d/plugin_max/nel_mesh_lib/CMakeLists.txt +++ b/code/nel/tools/3d/plugin_max/nel_mesh_lib/CMakeLists.txt @@ -12,4 +12,4 @@ IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(nel_mesh_lib ${CMAKE_CURRENT_SOURCE_DIR}/StdAfx.h ${CMAKE_CURRENT_SOURCE_DIR}/StdAfx.cpp) ENDIF(WITH_PCH) -INSTALL(TARGETS nel_mesh_lib RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +INSTALL(TARGETS nel_mesh_lib RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) diff --git a/code/nel/tools/3d/plugin_max/nel_patch_converter/CMakeLists.txt b/code/nel/tools/3d/plugin_max/nel_patch_converter/CMakeLists.txt index d414375ba..c173232b3 100644 --- a/code/nel/tools/3d/plugin_max/nel_patch_converter/CMakeLists.txt +++ b/code/nel/tools/3d/plugin_max/nel_patch_converter/CMakeLists.txt @@ -18,4 +18,4 @@ NL_DEFAULT_PROPS(nel_patch_converter "MAX Plugin: NeL Patch Converter") NL_ADD_RUNTIME_FLAGS(nel_patch_converter) NL_ADD_LIB_SUFFIX(nel_patch_converter) -INSTALL(TARGETS nel_patch_converter RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +INSTALL(TARGETS nel_patch_converter RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) diff --git a/code/nel/tools/3d/plugin_max/nel_patch_edit/CMakeLists.txt b/code/nel/tools/3d/plugin_max/nel_patch_edit/CMakeLists.txt index ff2c11245..82cc06611 100644 --- a/code/nel/tools/3d/plugin_max/nel_patch_edit/CMakeLists.txt +++ b/code/nel/tools/3d/plugin_max/nel_patch_edit/CMakeLists.txt @@ -22,4 +22,4 @@ IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(nel_patch_edit ${CMAKE_CURRENT_SOURCE_DIR}/stdafx.h ${CMAKE_CURRENT_SOURCE_DIR}/stdafx.cpp) ENDIF(WITH_PCH) -INSTALL(TARGETS nel_patch_edit RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +INSTALL(TARGETS nel_patch_edit RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) diff --git a/code/nel/tools/3d/plugin_max/nel_patch_lib/CMakeLists.txt b/code/nel/tools/3d/plugin_max/nel_patch_lib/CMakeLists.txt index faaac3f5d..63f0a5bcc 100644 --- a/code/nel/tools/3d/plugin_max/nel_patch_lib/CMakeLists.txt +++ b/code/nel/tools/3d/plugin_max/nel_patch_lib/CMakeLists.txt @@ -8,4 +8,4 @@ NL_DEFAULT_PROPS(nel_patch_lib "MAX Plugin: NeL Patch Library") NL_ADD_RUNTIME_FLAGS(nel_patch_lib) NL_ADD_LIB_SUFFIX(nel_patch_lib) -INSTALL(TARGETS nel_patch_lib RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +INSTALL(TARGETS nel_patch_lib RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) diff --git a/code/nel/tools/3d/plugin_max/nel_patch_paint/CMakeLists.txt b/code/nel/tools/3d/plugin_max/nel_patch_paint/CMakeLists.txt index 54f2c1724..628cb3120 100644 --- a/code/nel/tools/3d/plugin_max/nel_patch_paint/CMakeLists.txt +++ b/code/nel/tools/3d/plugin_max/nel_patch_paint/CMakeLists.txt @@ -24,5 +24,5 @@ NL_ADD_LIB_SUFFIX(nel_patch_paint) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) -INSTALL(TARGETS nel_patch_paint RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +INSTALL(TARGETS nel_patch_paint RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) INSTALL(FILES keys.cfg DESTINATION maxplugin/plugins ) \ No newline at end of file diff --git a/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/CMakeLists.txt b/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/CMakeLists.txt index 2f910ac9a..9c4f6deb2 100644 --- a/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/CMakeLists.txt +++ b/code/nel/tools/3d/plugin_max/nel_vertex_tree_paint/CMakeLists.txt @@ -19,4 +19,4 @@ NL_DEFAULT_PROPS(nel_vertex_tree_paint "MAX Plugin: NeL Vertex Tree Painter") NL_ADD_RUNTIME_FLAGS(nel_vertex_tree_paint) NL_ADD_LIB_SUFFIX(nel_vertex_tree_paint) -INSTALL(TARGETS nel_vertex_tree_paint RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +INSTALL(TARGETS nel_vertex_tree_paint RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) diff --git a/code/nel/tools/3d/plugin_max/tile_utility/CMakeLists.txt b/code/nel/tools/3d/plugin_max/tile_utility/CMakeLists.txt index 772efe8b9..7f0122cda 100644 --- a/code/nel/tools/3d/plugin_max/tile_utility/CMakeLists.txt +++ b/code/nel/tools/3d/plugin_max/tile_utility/CMakeLists.txt @@ -18,4 +18,4 @@ NL_DEFAULT_PROPS(tile_utility "MAX Plugin: Tile Utility") NL_ADD_RUNTIME_FLAGS(tile_utility) NL_ADD_LIB_SUFFIX(tile_utility) -INSTALL(TARGETS tile_utility RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION lib ARCHIVE DESTINATION lib COMPONENT libraries) +INSTALL(TARGETS tile_utility RUNTIME DESTINATION maxplugin/plugins LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT libraries) diff --git a/code/nel/tools/3d/s3tc_compressor_lib/CMakeLists.txt b/code/nel/tools/3d/s3tc_compressor_lib/CMakeLists.txt new file mode 100644 index 000000000..4062f6905 --- /dev/null +++ b/code/nel/tools/3d/s3tc_compressor_lib/CMakeLists.txt @@ -0,0 +1,16 @@ +FILE(GLOB SRC *.cpp) +FILE(GLOB HEADER *.h) + +INCLUDE_DIRECTORIES(${SQUISH_INCLUDE_DIR}) + +NL_TARGET_LIB(s3tc_compressor ${SRC} ${HEADER}) + +TARGET_LINK_LIBRARIES(s3tc_compressor ${SQUISH_LIBRARIES} nelmisc nel3d) +NL_DEFAULT_PROPS(s3tc_compressor "NeL, Tools, 3D: S3TC Compressor Library") +NL_ADD_RUNTIME_FLAGS(s3tc_compressor) + +ADD_DEFINITIONS(${SQUISH_DEFINITIONS}) + +IF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) + INSTALL(TARGETS s3tc_compressor LIBRARY DESTINATION ${NL_LIB_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT tools3d) +ENDIF((WITH_INSTALL_LIBRARIES AND WITH_STATIC) OR NOT WITH_STATIC) diff --git a/code/nel/tools/3d/s3tc_compressor_lib/s3tc_compressor.cpp b/code/nel/tools/3d/s3tc_compressor_lib/s3tc_compressor.cpp index a004a2716..0d2ea6a7e 100644 --- a/code/nel/tools/3d/s3tc_compressor_lib/s3tc_compressor.cpp +++ b/code/nel/tools/3d/s3tc_compressor_lib/s3tc_compressor.cpp @@ -60,8 +60,12 @@ static void compressMipMap(uint8 *pixSrc, sint width, sint height, vector +// Copyright (C) 2010 Winch Gate Property Limited +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as +// published by the Free Software Foundation, either version 3 of the +// License, or (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with this program. If not, see . + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +using namespace NLMISC; +using namespace NL3D; +using namespace std; + +struct CVertex +{ + CVector vertex; + CVector normal; + CUV uv; +}; + +bool operator == (const CVertex &v1, const CVertex &v2) +{ + return (v1.vertex == v2.vertex) && (v1.normal == v2.normal) && (v1.uv == v2.uv); +} + +bool operator < (const CVertex &v1, const CVertex &v2) +{ + return (v1.vertex < v2.vertex); +} + +const CIndexBuffer *getRdrPassPrimitiveBlock(const CMeshMRMGeom *mesh, uint lodId, uint renderPass) +{ + return &(mesh->getRdrPassPrimitiveBlock(lodId, renderPass)); +} + +// *************************************************************************** + +const CIndexBuffer *getRdrPassPrimitiveBlock(const CMeshMRMSkinnedGeom *mesh, uint lodId, uint renderPass) +{ + static CIndexBuffer block; + mesh->getRdrPassPrimitiveBlock(lodId, renderPass, block); + return █ +} + +// *************************************************************************** + +bool ProcessMeshMRMSkinned(const std::string &filename, IShape *shapeMesh); +bool ProcessMeshMRM(const std::string &filename, IShape *shapeMesh); +bool ProcessMesh(const std::string &filename, IShape *shapeMesh); + +int main(int argc, char* argv[]) +{ + if (argc < 2) + { + cout << "Syntax : shape2obj " << endl; + + return 1; + } + + if (!NLMISC::INelContext::isContextInitialised()) new NLMISC::CApplicationContext(); + + registerSerial3d(); + CScene::registerBasics(); + + IShape *shapeMesh = NULL; + + CIFile ifile; + + // Sream a shape + CShapeStream streamShape; + + string filename = argv[1]; + + if (!ifile.open(filename)) return 1; + + try + { + // Stream it + streamShape.serial(ifile); + + // Add the shape + shapeMesh = streamShape.getShapePointer(); + } + catch (Exception& e) + { + cout << "Error : " << e.what() << endl; + + return 1; + } + + if (ProcessMeshMRMSkinned(filename, shapeMesh)) return 0; + if (ProcessMeshMRM(filename, shapeMesh)) return 0; + if (ProcessMesh(filename, shapeMesh)) return 0; + + return 0; +} + +bool ProcessMeshMRMSkinned(const std::string &filename, IShape *shapeMesh) +{ + CMeshMRMSkinned *mesh = dynamic_cast(shapeMesh); + + if (!mesh) return false; + + COFile ofile; + + CMeshMRMSkinnedGeom* meshIn = (CMeshMRMSkinnedGeom*)&mesh->getMeshGeom(); + + std::vector skinWeights; + meshIn->getSkinWeights(skinWeights); + CVertexBuffer vertexBuffer; + meshIn->getVertexBuffer(vertexBuffer); + + CVertexBufferRead vba; + vertexBuffer.lock (vba); + uint i, j; + + // **** Select the Lod. + uint numLods= meshIn->getNbLod(); + + // get the max tris displayed + float numMeshFacesMin= (float)meshIn->getLevelDetail().MinFaceUsed; + float numMeshFacesMax= (float)meshIn->getLevelDetail().MaxFaceUsed; + // find the lod + sint lodId = numLods-1; + + // **** First, for the best lod indicate what vertex is used or not. Also index geomorphs to know what real vertex is used + vector vertexUsed; + // -1 means "not used" + vertexUsed.resize(skinWeights.size(), -1); + // Parse all triangles. + for(i=0;igetNbRdrPass(lodId); ++i) + { + const CIndexBuffer *pb = getRdrPassPrimitiveBlock(meshIn, lodId, i); + CIndexBufferRead iba; + pb->lock (iba); + if (iba.getFormat() == CIndexBuffer::Indices32) + { + const uint32 *triPtr= (const uint32 *) iba.getPtr(); + for(j=0;jgetNumIndexes(); ++j) + { + uint idx= *triPtr; + // Flag the vertex with its own index => used. + vertexUsed[idx]= idx; + triPtr++; + } + } + else + { + const uint16 *triPtr= (const uint16 *) iba.getPtr(); + for(j=0;jgetNumIndexes(); ++j) + { + uint idx= *triPtr; + // Flag the vertex with its own index => used. + vertexUsed[idx]= idx; + triPtr++; + } + } + } + // Special for Geomorphs: must take The End target vertex. + const std::vector &geomorphs= meshIn->getGeomorphs(lodId); + for(i=0;i shadowVertices; + vector vertexToVSkin; + vertexToVSkin.resize(vertexUsed.size()); + shadowVertices.reserve(vertexUsed.size()); + // use a map to remove duplicates (because of UV/normal discontinuities before!!) + map shadowVertexMap; + uint numMerged= 0; + // Skip Geomorphs. + for(i=geomorphs.size();imaxW) + { + matId= sw.MatrixId[j]; + maxW= sw.Weights[j]; + } + } +// shadowVert.MatrixId= matId; +*/ + // If dont find the shadowVertex in the map. + map::iterator it= shadowVertexMap.find(shadowVert); + if(it==shadowVertexMap.end()) + { + // Append + uint index= shadowVertices.size(); + vertexToVSkin[i]= index; + shadowVertices.push_back(shadowVert); + shadowVertexMap.insert(make_pair(shadowVert, index)); + } + else + { + // Ok, map. + vertexToVSkin[i]= it->second; + numMerged++; + } + + } + } + + ofstream ofs(string(filename + ".obj").c_str()); + + for(size_t y = 0; y < shadowVertices.size(); ++y) + { + CVector v = shadowVertices[y].vertex; + CVector vn = shadowVertices[y].normal; + CUV vt = shadowVertices[y].uv; + + ofs << "v " << v.x << " " << v.y << " " << v.z << endl; + ofs << "vn " << vn.x << " " << vn.y << " " << vn.z << endl; + ofs << "vt " << vt.U << " " << vt.V << endl; + } + + // **** Get All Faces + // Final List Of Triangles that match the bone. + vector shadowTriangles; + shadowTriangles.reserve(1000); + // Parse all input tri of the mesh. + for(i=0; igetNbRdrPass(lodId); ++i) + { + ofs << "g pass" << i << endl; + + const CIndexBuffer *pb = getRdrPassPrimitiveBlock(meshIn, lodId, i); + CIndexBufferRead iba; + pb->lock (iba); + if (iba.getFormat() == CIndexBuffer::Indices32) + { + const uint32 *triPtr= (const uint32 *) iba.getPtr(); + + for(j=0; jgetNumIndexes(); ++j) + { + uint idx= *triPtr; + // Get the real Vertex (ie not the geomporhed one). + idx= vertexUsed[idx]; + // Get the ShadowVertex associated + idx= vertexToVSkin[idx]; + + shadowTriangles.push_back(idx); + triPtr++; + } + } + else + { + const uint16 *triPtr= (const uint16 *) iba.getPtr(); + for(j=0; jgetNumIndexes(); ++j) + { + uint idx= *triPtr; + // Get the real Vertex (ie not the geomporhed one). + idx= vertexUsed[idx]; + // Get the ShadowVertex associated + idx= vertexToVSkin[idx]; + + shadowTriangles.push_back(idx); + triPtr++; + } + } + + for(size_t pass = 0; pass(shapeMesh); + + if (!mesh) return false; + + COFile ofile; + + CMeshMRMGeom* meshIn = (CMeshMRMGeom*)&mesh->getMeshGeom(); + + std::vector skinWeights = meshIn->getSkinWeights(); + CVertexBuffer vertexBuffer = meshIn->getVertexBuffer(); + + CVertexBufferRead vba; + vertexBuffer.lock (vba); + uint i, j; + + // **** Select the Lod. + uint numLods= meshIn->getNbLod(); + + // get the max tris displayed + float numMeshFacesMin= (float)meshIn->getLevelDetail().MinFaceUsed; + float numMeshFacesMax= (float)meshIn->getLevelDetail().MaxFaceUsed; + // find the lod + sint lodId = numLods-1; + + // **** First, for the best lod indicate what vertex is used or not. Also index geomorphs to know what real vertex is used + vector vertexUsed; + // -1 means "not used" + vertexUsed.resize(skinWeights.size(), -1); + // Parse all triangles. + for(i=0;igetNbRdrPass(lodId); ++i) + { + const CIndexBuffer *pb = getRdrPassPrimitiveBlock(meshIn, lodId, i); + CIndexBufferRead iba; + pb->lock (iba); + if (iba.getFormat() == CIndexBuffer::Indices32) + { + const uint32 *triPtr= (const uint32 *) iba.getPtr(); + for(j=0;jgetNumIndexes(); ++j) + { + uint idx= *triPtr; + // Flag the vertex with its own index => used. + vertexUsed[idx]= idx; + triPtr++; + } + } + else + { + const uint16 *triPtr= (const uint16 *) iba.getPtr(); + for(j=0;jgetNumIndexes(); ++j) + { + uint idx= *triPtr; + // Flag the vertex with its own index => used. + vertexUsed[idx]= idx; + triPtr++; + } + } + } + // Special for Geomorphs: must take The End target vertex. + const std::vector &geomorphs= meshIn->getGeomorphs(lodId); + for(i=0;i shadowVertices; + vector vertexToVSkin; + vertexToVSkin.resize(vertexUsed.size()); + shadowVertices.reserve(vertexUsed.size()); + // use a map to remove duplicates (because of UV/normal discontinuities before!!) + map shadowVertexMap; + uint numMerged= 0; + // Skip Geomorphs. + for(i=geomorphs.size();imaxW) + { + matId= sw.MatrixId[j]; + maxW= sw.Weights[j]; + } + } +// shadowVert.MatrixId= matId; +*/ + // If dont find the shadowVertex in the map. + map::iterator it= shadowVertexMap.find(shadowVert); + if(it==shadowVertexMap.end()) + { + // Append + uint index= shadowVertices.size(); + vertexToVSkin[i]= index; + shadowVertices.push_back(shadowVert); + shadowVertexMap.insert(make_pair(shadowVert, index)); + } + else + { + // Ok, map. + vertexToVSkin[i]= it->second; + numMerged++; + } + + } + } + + ofstream ofs(string(filename + ".obj").c_str()); + + for(size_t y = 0; y < shadowVertices.size(); ++y) + { + CVector v = shadowVertices[y].vertex; + CVector vn = shadowVertices[y].normal; + CUV vt = shadowVertices[y].uv; + + ofs << "v " << v.x << " " << v.y << " " << v.z << endl; + ofs << "vn " << vn.x << " " << vn.y << " " << vn.z << endl; + ofs << "vt " << vt.U << " " << vt.V << endl; + } + + // **** Get All Faces + // Final List Of Triangles that match the bone. + vector shadowTriangles; + shadowTriangles.reserve(1000); + // Parse all input tri of the mesh. + for(i=0; igetNbRdrPass(lodId); ++i) + { + ofs << "g pass" << i << endl; + + const CIndexBuffer *pb = getRdrPassPrimitiveBlock(meshIn, lodId, i); + CIndexBufferRead iba; + pb->lock (iba); + if (iba.getFormat() == CIndexBuffer::Indices32) + { + const uint32 *triPtr= (const uint32 *) iba.getPtr(); + + for(j=0; jgetNumIndexes(); ++j) + { + uint idx= *triPtr; + // Get the real Vertex (ie not the geomporhed one). + idx= vertexUsed[idx]; + // Get the ShadowVertex associated + idx= vertexToVSkin[idx]; + + shadowTriangles.push_back(idx); + triPtr++; + } + } + else + { + const uint16 *triPtr= (const uint16 *) iba.getPtr(); + for(j=0; jgetNumIndexes(); ++j) + { + uint idx= *triPtr; + // Get the real Vertex (ie not the geomporhed one). + idx= vertexUsed[idx]; + // Get the ShadowVertex associated + idx= vertexToVSkin[idx]; + + shadowTriangles.push_back(idx); + triPtr++; + } + } + + for(size_t pass = 0; pass(shapeMesh); + + if (!mesh) return false; + + COFile ofile; + + CMeshGeom* meshIn = (CMeshGeom*)&mesh->getMeshGeom(); + + CVertexBuffer vertexBuffer = meshIn->getVertexBuffer(); + +// CVertexBufferRead vba; +// vertexBuffer.lock (vba); + + uint i = vertexBuffer.getNumVertices(); + + std::vector vertices; + meshIn->retrieveVertices(vertices); + + std::vector indices; + meshIn->retrieveTriangles(indices); + + + // **** For all vertices used (not geomorphs), compute vertex Skins. + vector shadowVertices; + vector vertexToVSkin; + vertexToVSkin.resize(indices.size()); + shadowVertices.reserve(indices.size()); + // use a map to remove duplicates (because of UV/normal discontinuities before!!) + map shadowVertexMap; + uint numMerged= 0; + // Skip Geomorphs. + for(i=0;imaxW) + { + matId= sw.MatrixId[j]; + maxW= sw.Weights[j]; + } + } + + // If dont find the shadowVertex in the map. + map::iterator it= shadowVertexMap.find(shadowVert); + if(it==shadowVertexMap.end()) + { + // Append + uint index= shadowVertices.size(); + vertexToVSkin[i]= index; + shadowVertices.push_back(shadowVert); + shadowVertexMap.insert(make_pair(shadowVert, index)); + } + else + { + // Ok, map. + vertexToVSkin[i]= it->second; + numMerged++; + } + } + + ofstream ofs(string(filename + ".obj").c_str()); + + for(size_t y = 0; y < shadowVertices.size(); ++y) + { + CVector v = shadowVertices[y].vertex; + CVector vn = shadowVertices[y].normal; + CUV vt = shadowVertices[y].uv; + + ofs << "v " << v.x << " " << v.y << " " << v.z << endl; + ofs << "vn " << vn.x << " " << vn.y << " " << vn.z << endl; + ofs << "vt " << vt.U << " " << vt.V << endl; + } + + // **** Get All Faces + // Final List Of Triangles that match the bone. + vector shadowTriangles; + shadowTriangles.reserve(1000); + // Parse all input tri of the mesh. + for(i=0; igetNbRdrPass(lodId); ++i) + { + ofs << "g pass" << i << endl; + + const CIndexBuffer *pb = getRdrPassPrimitiveBlock(meshIn, lodId, i); + CIndexBufferRead iba; + pb->lock (iba); + if (iba.getFormat() == CIndexBuffer::Indices32) + { + const uint32 *triPtr= (const uint32 *) iba.getPtr(); + + for(j=0; jgetNumIndexes(); ++j) + { + uint idx= *triPtr; + // Get the real Vertex (ie not the geomporhed one). + idx= vertexUsed[idx]; + // Get the ShadowVertex associated + idx= vertexToVSkin[idx]; + + shadowTriangles.push_back(idx); + triPtr++; + } + } + else + { + const uint16 *triPtr= (const uint16 *) iba.getPtr(); + for(j=0; jgetNumIndexes(); ++j) + { + uint idx= *triPtr; + // Get the real Vertex (ie not the geomporhed one). + idx= vertexUsed[idx]; + // Get the ShadowVertex associated + idx= vertexToVSkin[idx]; + + shadowTriangles.push_back(idx); + triPtr++; + } + } + + for(size_t pass = 0; passclearTile128 (index, bitmap, tileBankBrowser); } @@ -622,6 +630,8 @@ void TileList::clearTile256 (int index, CTile::TBitmap bitmap) case CTile::alpha: nlassert(0); break; + default: + break; } tileBankBrowser.getTileSet (_tileSet)->clearTile256 (index, bitmap, tileBankBrowser); } @@ -642,6 +652,8 @@ void TileList::clearTransition (int index, CTile::TBitmap bitmap) theListTransition[index].alphaLoaded=0; theListTransition[index].alphaBits.resize(0); break; + default: + break; } tileBankBrowser.getTileSet (_tileSet)->clearTransition ((CTileSet::TTransition)index, bitmap, tileBankBrowser); } @@ -660,6 +672,8 @@ void TileList::clearDisplacement (int index, CTile::TBitmap bitmap) case CTile::alpha: nlassert(0); break; + default: + break; } tileBankBrowser.getTileSet (_tileSet)->clearDisplacement ((CTileSet::TDisplacement)index, tileBankBrowser); @@ -717,7 +731,8 @@ void TileList::Reload(int first, int last, TileType n) //recharge en memoire une theList[n][i].Load (index, NULL); break; } - + default: + break; } } } diff --git a/code/nel/tools/3d/tile_edit_qt/pic/PIC_System.c b/code/nel/tools/3d/tile_edit_qt/pic/PIC_System.c index 4e97fed78..498e5d302 100644 --- a/code/nel/tools/3d/tile_edit_qt/pic/PIC_System.c +++ b/code/nel/tools/3d/tile_edit_qt/pic/PIC_System.c @@ -8,8 +8,8 @@ #define PIC_ERRSIZE 256 -static unsigned long PIC_Sys_MEM_Allocated; -static unsigned long PIC_Sys_MEM_NbAllocs; +static size_t PIC_Sys_MEM_Allocated; +static size_t PIC_Sys_MEM_NbAllocs; #if defined(__APPLE__) #define _msize malloc_size @@ -31,7 +31,7 @@ void *Pic_malloc(unsigned long size) return(mem); } /* ----- */ -void *Pic_calloc(unsigned long count, unsigned long size) +void *Pic_calloc(size_t count, size_t size) { void *mem; mem=calloc(count,size); @@ -45,24 +45,24 @@ void *Pic_calloc(unsigned long count, unsigned long size) /* ----- */ void Pic_free(void *memblock) { - unsigned long size; + size_t size; size=_msize(memblock); PIC_Sys_MEM_Allocated-=size; PIC_Sys_MEM_NbAllocs--; free(memblock); } /* ----- */ -unsigned long Pic__msize(void *memblock) +size_t Pic__msize(void *memblock) { return(_msize(memblock)); } /* ----- */ -unsigned long PIC_GetMemNbAllocs(void) +size_t PIC_GetMemNbAllocs(void) { return(PIC_Sys_MEM_NbAllocs); } /* ----- */ -unsigned long PIC_GetMemAllocated(void) +size_t PIC_GetMemAllocated(void) { return(PIC_Sys_MEM_Allocated); } @@ -74,7 +74,7 @@ static unsigned char PIC_ErrorString[PIC_ERRSIZE]; static unsigned char PIC_Sys_FnctActive=0; static void (*PIC_Sys_Fnct)(void); -void Pic_SetError(unsigned char *msg, ...) +void Pic_SetError(const char *msg, ...) { unsigned char curerr[PIC_ERRSIZE],olderr[PIC_ERRSIZE]; va_list args; diff --git a/code/nel/tools/3d/tile_edit_qt/pic/Pic_BMP.c b/code/nel/tools/3d/tile_edit_qt/pic/Pic_BMP.c index 332ee1b0d..1119766da 100644 --- a/code/nel/tools/3d/tile_edit_qt/pic/Pic_BMP.c +++ b/code/nel/tools/3d/tile_edit_qt/pic/Pic_BMP.c @@ -31,7 +31,7 @@ typedef struct BMP_HEADER /* ---------------------------------------------------------------------------------------------------------------------------------- */ -unsigned long Pic_BMP_Write( unsigned char *FileName, +unsigned long Pic_BMP_Write( const char *FileName, unsigned char *pPal,unsigned char *pDatas, unsigned long w, unsigned long h, unsigned long d) @@ -117,7 +117,7 @@ unsigned long Pic_BMP_Write( unsigned char *FileName, /* ---------------------------------------------------------------------------------------------------------------------------------- */ -unsigned long Pic_BMP_Read( unsigned char *FileName, +unsigned long Pic_BMP_Read( const char *FileName, unsigned char **ppPal, unsigned char **ppDatas, unsigned long *pWidth, unsigned long *pHeight, unsigned long *pDepth) diff --git a/code/nel/tools/3d/tile_edit_qt/pic/Pic_JPG.c b/code/nel/tools/3d/tile_edit_qt/pic/Pic_JPG.c index f13f93b13..dc22afadf 100644 --- a/code/nel/tools/3d/tile_edit_qt/pic/Pic_JPG.c +++ b/code/nel/tools/3d/tile_edit_qt/pic/Pic_JPG.c @@ -31,7 +31,7 @@ void my_error_exit(j_common_ptr cinfo) /* ---------------------------------------------------------------------------------------------------------------------------------- */ -unsigned long Pic_JPG_Read(unsigned char *FileName, unsigned char **ppPal, unsigned char **ppDatas, unsigned long *w, unsigned long *h) +unsigned long Pic_JPG_Read(const char *FileName, unsigned char **ppPal, unsigned char **ppDatas, unsigned long *w, unsigned long *h) { struct jpeg_decompress_struct cinfo; struct my_error_mgr jerr; @@ -114,7 +114,7 @@ unsigned long Pic_JPG_Read(unsigned char *FileName, unsigned char **ppPal, unsig /* ---------------------------------------------------------------------------------------------------------------------------------- */ -unsigned long Pic_JPG_Write(unsigned char *FileName, unsigned long Qual, unsigned char *pDatas, unsigned long w, unsigned long h) +unsigned long Pic_JPG_Write(const char *FileName, unsigned long Qual, unsigned char *pDatas, unsigned long w, unsigned long h) { struct jpeg_compress_struct cinfo; struct my_error_mgr jerr; diff --git a/code/nel/tools/3d/tile_edit_qt/pic/Pic_Manage.c b/code/nel/tools/3d/tile_edit_qt/pic/Pic_Manage.c index 6efaf0f03..ccc8cdc12 100644 --- a/code/nel/tools/3d/tile_edit_qt/pic/Pic_Manage.c +++ b/code/nel/tools/3d/tile_edit_qt/pic/Pic_Manage.c @@ -504,7 +504,7 @@ static char* ConvPic(PIC_PICTURE *pic, unsigned long type, char* pErr) /* ---------------------------------------- */ -unsigned long PIC_Save(unsigned long id, char* FileName, unsigned long type, unsigned long qual) +unsigned long PIC_Save(unsigned long id, const char* FileName, unsigned long type, unsigned long qual) { PIC_PICTURE *pic; unsigned char err; diff --git a/code/nel/tools/3d/tile_edit_qt/pic/Pic_TGA.c b/code/nel/tools/3d/tile_edit_qt/pic/Pic_TGA.c index 5f598d4eb..4c458dc83 100644 --- a/code/nel/tools/3d/tile_edit_qt/pic/Pic_TGA.c +++ b/code/nel/tools/3d/tile_edit_qt/pic/Pic_TGA.c @@ -27,7 +27,7 @@ typedef struct TGA_HEADER /* ---------------------------------------------------------------------------------------------------------------------------------- */ -unsigned long Pic_TGA_Read( unsigned char *FileName, +unsigned long Pic_TGA_Read( const char *FileName, unsigned char **ppPal, unsigned char **ppDatas, unsigned long *pWidth, unsigned long *pHeight, unsigned long *pDepth) @@ -140,7 +140,7 @@ unsigned long Pic_TGA_Read( unsigned char *FileName, /* ---------------------------------------------------------------------------------------------------------------------------------- */ -unsigned long Pic_TGA_Write( unsigned char *FileName, +unsigned long Pic_TGA_Write( const char *FileName, unsigned char *pPal,unsigned char *pDatas, unsigned long w, unsigned long h, unsigned long d) { diff --git a/code/nel/tools/3d/tile_edit_qt/pic/pic.h b/code/nel/tools/3d/tile_edit_qt/pic/pic.h index 761073552..cec5a0ff0 100644 --- a/code/nel/tools/3d/tile_edit_qt/pic/pic.h +++ b/code/nel/tools/3d/tile_edit_qt/pic/pic.h @@ -22,7 +22,7 @@ extern unsigned long PIC_Load(char* FileName, unsigned char Quantize); extern unsigned long PIC_Create(unsigned char* pPal, unsigned char* pDatas, unsigned long w, unsigned long h, unsigned long d); -extern unsigned long PIC_Save(unsigned long id, char* FileName, unsigned long type, unsigned long qual); +extern unsigned long PIC_Save(unsigned long id, const char* FileName, unsigned long type, unsigned long qual); extern unsigned long PIC_GetInfos( unsigned long id, unsigned char* *ppPal, unsigned char* *ppDatas, diff --git a/code/nel/tools/3d/tile_edit_qt/pic/pic_private.h b/code/nel/tools/3d/tile_edit_qt/pic/pic_private.h index 2ecd984b7..96b7a0e94 100644 --- a/code/nel/tools/3d/tile_edit_qt/pic/pic_private.h +++ b/code/nel/tools/3d/tile_edit_qt/pic/pic_private.h @@ -1,71 +1,71 @@ -#ifndef _PIC_PRIVATE_H_ -#define _PIC_PRIVATE_H_ -#ifdef __cplusplus -extern "C" { -#endif - -/* ---------------------------------------------------------------------------------------------------------------------------------- */ - -typedef struct PIC_PICTURE -{ - unsigned long ID; - unsigned long Width; - unsigned long Height; - unsigned long Depth; - unsigned char *pDatas; - unsigned char *pPal; - struct PIC_PICTURE *Next; -} PIC_PICTURE; - -/* ---------------------------------------------------------------------------------------------------------------------------------- */ - - -/* - * JPG - */ - - -extern unsigned long Pic_JPG_Read( unsigned char *FileName, - unsigned char **ppPal, unsigned char **ppDatas, - unsigned long *w, unsigned long *h); - -extern unsigned long Pic_JPG_Write( unsigned char *FileName, - unsigned long Qual, - unsigned char *pDatas, - unsigned long w, unsigned long h); -/* - * TGA - */ -extern unsigned long Pic_TGA_Read( unsigned char *FileName, - unsigned char **ppPal, unsigned char **ppDatas, - unsigned long *pWidth, unsigned long *pHeight, - unsigned long *pDepth); -extern unsigned long Pic_TGA_Write( unsigned char *FileName, - unsigned char *pPal,unsigned char *pDatas, - unsigned long w, unsigned long h, unsigned long d); -/* - * BMP - */ -extern unsigned long Pic_BMP_Read( unsigned char *FileName, - unsigned char **ppPal, unsigned char **ppDatas, - unsigned long *pWidth, unsigned long *pHeight, - unsigned long *pDepth); - -extern unsigned long Pic_BMP_Write( unsigned char *FileName, - unsigned char *pPal,unsigned char *pDatas, - unsigned long w, unsigned long h, unsigned long d); -/* - * System - */ -extern void* Pic_malloc(unsigned long size); -extern void* Pic_calloc(unsigned long count, unsigned long size); -extern void Pic_free(void *memblock); -extern unsigned long Pic__msize(void *memblock); -extern void Pic_SetError(unsigned char *msg, ...); - -/* ---------------------------------------------------------------------------------------------------------------------------------- */ - -#ifdef __cplusplus -} -#endif +#ifndef _PIC_PRIVATE_H_ +#define _PIC_PRIVATE_H_ +#ifdef __cplusplus +extern "C" { +#endif + +/* ---------------------------------------------------------------------------------------------------------------------------------- */ + +typedef struct PIC_PICTURE +{ + unsigned long ID; + unsigned long Width; + unsigned long Height; + unsigned long Depth; + unsigned char *pDatas; + unsigned char *pPal; + struct PIC_PICTURE *Next; +} PIC_PICTURE; + +/* ---------------------------------------------------------------------------------------------------------------------------------- */ + + +/* + * JPG + */ + + +extern unsigned long Pic_JPG_Read( const char *FileName, + unsigned char **ppPal, unsigned char **ppDatas, + unsigned long *w, unsigned long *h); + +extern unsigned long Pic_JPG_Write( const char *FileName, + unsigned long Qual, + unsigned char *pDatas, + unsigned long w, unsigned long h); +/* + * TGA + */ +extern unsigned long Pic_TGA_Read( const char *FileName, + unsigned char **ppPal, unsigned char **ppDatas, + unsigned long *pWidth, unsigned long *pHeight, + unsigned long *pDepth); +extern unsigned long Pic_TGA_Write( const char *FileName, + unsigned char *pPal,unsigned char *pDatas, + unsigned long w, unsigned long h, unsigned long d); +/* + * BMP + */ +extern unsigned long Pic_BMP_Read( const char *FileName, + unsigned char **ppPal, unsigned char **ppDatas, + unsigned long *pWidth, unsigned long *pHeight, + unsigned long *pDepth); + +extern unsigned long Pic_BMP_Write( const char *FileName, + unsigned char *pPal,unsigned char *pDatas, + unsigned long w, unsigned long h, unsigned long d); +/* + * System + */ +extern void* Pic_malloc(size_t size); +extern void* Pic_calloc(size_t count, size_t size); +extern void Pic_free(void *memblock); +extern size_t Pic__msize(void *memblock); +extern void Pic_SetError(const char *msg, ...); + +/* ---------------------------------------------------------------------------------------------------------------------------------- */ + +#ifdef __cplusplus +} +#endif #endif diff --git a/code/nel/tools/3d/zone_check_bind/CMakeLists.txt b/code/nel/tools/3d/zone_check_bind/CMakeLists.txt index b0b059341..212f7e18b 100644 --- a/code/nel/tools/3d/zone_check_bind/CMakeLists.txt +++ b/code/nel/tools/3d/zone_check_bind/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(zone_check_bind nel3d nelmisc) NL_DEFAULT_PROPS(zone_check_bind "NeL, Tools, 3D: zone_check_bind") NL_ADD_RUNTIME_FLAGS(zone_check_bind) -INSTALL(TARGETS zone_check_bind RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS zone_check_bind RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/zone_dependencies/CMakeLists.txt b/code/nel/tools/3d/zone_dependencies/CMakeLists.txt index f841a30c0..9efb49f0e 100644 --- a/code/nel/tools/3d/zone_dependencies/CMakeLists.txt +++ b/code/nel/tools/3d/zone_dependencies/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(zone_dependencies nel3d nelgeorges nelmisc) NL_DEFAULT_PROPS(zone_dependencies "NeL, Tools, 3D: zone_dependencies") NL_ADD_RUNTIME_FLAGS(zone_dependencies) -INSTALL(TARGETS zone_dependencies RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS zone_dependencies RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/zone_dump/CMakeLists.txt b/code/nel/tools/3d/zone_dump/CMakeLists.txt index e9f162fb3..8bc10b811 100644 --- a/code/nel/tools/3d/zone_dump/CMakeLists.txt +++ b/code/nel/tools/3d/zone_dump/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(zone_dump nel3d nelmisc) NL_DEFAULT_PROPS(zone_dump "NeL, Tools, 3D: zone_dump") NL_ADD_RUNTIME_FLAGS(zone_dump) -INSTALL(TARGETS zone_dump RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS zone_dump RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/zone_ig_lighter/CMakeLists.txt b/code/nel/tools/3d/zone_ig_lighter/CMakeLists.txt index 096469b5e..30f84cea8 100644 --- a/code/nel/tools/3d/zone_ig_lighter/CMakeLists.txt +++ b/code/nel/tools/3d/zone_ig_lighter/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(zone_ig_lighter nelmisc nel3d) NL_DEFAULT_PROPS(zone_ig_lighter "NeL, Tools, 3D: zone_ig_lighter") NL_ADD_RUNTIME_FLAGS(zone_ig_lighter) -INSTALL(TARGETS zone_ig_lighter RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS zone_ig_lighter RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/zone_lighter/CMakeLists.txt b/code/nel/tools/3d/zone_lighter/CMakeLists.txt index 816b8a841..e0c15f9e8 100644 --- a/code/nel/tools/3d/zone_lighter/CMakeLists.txt +++ b/code/nel/tools/3d/zone_lighter/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(zone_lighter nel3d nelgeorges nelmisc) NL_DEFAULT_PROPS(zone_lighter "NeL, Tools, 3D: zone_lighter") NL_ADD_RUNTIME_FLAGS(zone_lighter) -INSTALL(TARGETS zone_lighter RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS zone_lighter RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/zone_welder/CMakeLists.txt b/code/nel/tools/3d/zone_welder/CMakeLists.txt index 2e8acb118..396d22f58 100644 --- a/code/nel/tools/3d/zone_welder/CMakeLists.txt +++ b/code/nel/tools/3d/zone_welder/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(zone_welder nel3d nelmisc) NL_DEFAULT_PROPS(zone_welder "NeL, Tools, 3D: zone_welder") NL_ADD_RUNTIME_FLAGS(zone_welder) -INSTALL(TARGETS zone_welder RUNTIME DESTINATION bin COMPONENT tools3d) +INSTALL(TARGETS zone_welder RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) diff --git a/code/nel/tools/3d/zviewer/CMakeLists.txt b/code/nel/tools/3d/zviewer/CMakeLists.txt index 04d72ff27..a7a5150b7 100644 --- a/code/nel/tools/3d/zviewer/CMakeLists.txt +++ b/code/nel/tools/3d/zviewer/CMakeLists.txt @@ -12,6 +12,6 @@ TARGET_LINK_LIBRARIES(zviewer nelmisc nel3d) NL_DEFAULT_PROPS(zviewer "NeL, Tools, 3D: Zone Viewer") NL_ADD_RUNTIME_FLAGS(zviewer) -INSTALL(TARGETS zviewer RUNTIME DESTINATION bin COMPONENT tools3d) -INSTALL(FILES zviewer.cfg DESTINATION etc/nel COMPONENT tools3d) -INSTALL(FILES readme.txt DESTINATION share/nel/zviewer COMPONENT tools3d) +INSTALL(TARGETS zviewer RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT tools3d) +INSTALL(FILES zviewer.cfg DESTINATION ${NL_ETC_PREFIX} COMPONENT tools3d) +INSTALL(FILES readme.txt DESTINATION ${NL_SHARE_PREFIX}/zviewer COMPONENT tools3d) diff --git a/code/nel/tools/georges/georges2csv/CMakeLists.txt b/code/nel/tools/georges/georges2csv/CMakeLists.txt index e64d85772..b52de14ea 100644 --- a/code/nel/tools/georges/georges2csv/CMakeLists.txt +++ b/code/nel/tools/georges/georges2csv/CMakeLists.txt @@ -10,4 +10,4 @@ NL_ADD_RUNTIME_FLAGS(georges2csv) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) -INSTALL(TARGETS georges2csv RUNTIME DESTINATION bin COMPONENT toolsgeorges) +INSTALL(TARGETS georges2csv RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsgeorges) diff --git a/code/nel/tools/logic/logic_editor_dll/CMakeLists.txt b/code/nel/tools/logic/logic_editor_dll/CMakeLists.txt index c2e0661d1..e538799a0 100644 --- a/code/nel/tools/logic/logic_editor_dll/CMakeLists.txt +++ b/code/nel/tools/logic/logic_editor_dll/CMakeLists.txt @@ -15,4 +15,4 @@ IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(logic_editor_dll ${CMAKE_CURRENT_SOURCE_DIR}/StdAfx.h ${CMAKE_CURRENT_SOURCE_DIR}/StdAfx.cpp) ENDIF(WITH_PCH) -INSTALL(TARGETS logic_editor_dll LIBRARY DESTINATION lib RUNTIME DESTINATION bin ARCHIVE DESTINATION lib COMPONENT toolsmisc) +INSTALL(TARGETS logic_editor_dll LIBRARY DESTINATION ${NL_LIB_PREFIX} RUNTIME DESTINATION ${NL_BIN_PREFIX} ARCHIVE DESTINATION ${NL_LIB_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/logic/logic_editor_exe/CMakeLists.txt b/code/nel/tools/logic/logic_editor_exe/CMakeLists.txt index 764a0901e..7a210a71a 100644 --- a/code/nel/tools/logic/logic_editor_exe/CMakeLists.txt +++ b/code/nel/tools/logic/logic_editor_exe/CMakeLists.txt @@ -10,4 +10,4 @@ IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(logic_editor ${CMAKE_CURRENT_SOURCE_DIR}/StdAfx.h ${CMAKE_CURRENT_SOURCE_DIR}/StdAfx.cpp) ENDIF(WITH_PCH) -INSTALL(TARGETS logic_editor RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS logic_editor RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/memory/memlog/CMakeLists.txt b/code/nel/tools/memory/memlog/CMakeLists.txt index 9b471519b..f479a1579 100644 --- a/code/nel/tools/memory/memlog/CMakeLists.txt +++ b/code/nel/tools/memory/memlog/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(memlog nelmisc) NL_DEFAULT_PROPS(memlog "NeL, Tools, Memory: memlog") NL_ADD_RUNTIME_FLAGS(memlog) -INSTALL(TARGETS memlog RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS memlog RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/bnp_make/CMakeLists.txt b/code/nel/tools/misc/bnp_make/CMakeLists.txt index d0e4c4aa0..d27252fb6 100644 --- a/code/nel/tools/misc/bnp_make/CMakeLists.txt +++ b/code/nel/tools/misc/bnp_make/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(bnp_make nelmisc) NL_DEFAULT_PROPS(bnp_make "NeL, Tools, Misc: bnp_make") NL_ADD_RUNTIME_FLAGS(bnp_make) -INSTALL(TARGETS bnp_make RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS bnp_make RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/branch_patcher/CMakeLists.txt b/code/nel/tools/misc/branch_patcher/CMakeLists.txt index 13cd96605..010e7defd 100644 --- a/code/nel/tools/misc/branch_patcher/CMakeLists.txt +++ b/code/nel/tools/misc/branch_patcher/CMakeLists.txt @@ -8,4 +8,4 @@ NL_ADD_RUNTIME_FLAGS(branch_patcher) ADD_DEFINITIONS(${MFC_DEFINITIONS}) -INSTALL(TARGETS branch_patcher RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS branch_patcher RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/data_mirror/CMakeLists.txt b/code/nel/tools/misc/data_mirror/CMakeLists.txt index 3b87782b5..9727576ba 100644 --- a/code/nel/tools/misc/data_mirror/CMakeLists.txt +++ b/code/nel/tools/misc/data_mirror/CMakeLists.txt @@ -8,4 +8,4 @@ NL_ADD_RUNTIME_FLAGS(data_mirror) ADD_DEFINITIONS(${MFC_DEFINITIONS}) -INSTALL(TARGETS data_mirror RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS data_mirror RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/disp_sheet_id/CMakeLists.txt b/code/nel/tools/misc/disp_sheet_id/CMakeLists.txt index 13b8cb09a..0ab03d736 100644 --- a/code/nel/tools/misc/disp_sheet_id/CMakeLists.txt +++ b/code/nel/tools/misc/disp_sheet_id/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(disp_sheet_id nelmisc) NL_DEFAULT_PROPS(disp_sheet_id "NeL, Tools, Misc: disp_sheet_id") NL_ADD_RUNTIME_FLAGS(disp_sheet_id) -INSTALL(TARGETS disp_sheet_id RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS disp_sheet_id RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/exec_timeout/CMakeLists.txt b/code/nel/tools/misc/exec_timeout/CMakeLists.txt index daadd75d5..18654e169 100644 --- a/code/nel/tools/misc/exec_timeout/CMakeLists.txt +++ b/code/nel/tools/misc/exec_timeout/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(exec_timeout nelmisc) NL_DEFAULT_PROPS(exec_timeout "NeL, Tools, Misc: exec_timeout") NL_ADD_RUNTIME_FLAGS(exec_timeout) -INSTALL(TARGETS exec_timeout RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS exec_timeout RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/extract_filename/CMakeLists.txt b/code/nel/tools/misc/extract_filename/CMakeLists.txt index c46e9f1fc..7f20cc6d6 100644 --- a/code/nel/tools/misc/extract_filename/CMakeLists.txt +++ b/code/nel/tools/misc/extract_filename/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(extract_filename nelmisc) NL_DEFAULT_PROPS(extract_filename "NeL, Tools, Misc: extract_filename") NL_ADD_RUNTIME_FLAGS(extract_filename) -INSTALL(TARGETS extract_filename RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS extract_filename RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/lock/CMakeLists.txt b/code/nel/tools/misc/lock/CMakeLists.txt index 23771299a..52afeee24 100644 --- a/code/nel/tools/misc/lock/CMakeLists.txt +++ b/code/nel/tools/misc/lock/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(lock nelmisc) NL_DEFAULT_PROPS(lock "NeL, Tools, Misc: lock") NL_ADD_RUNTIME_FLAGS(lock) -INSTALL(TARGETS lock RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS lock RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/log_analyser/CMakeLists.txt b/code/nel/tools/misc/log_analyser/CMakeLists.txt index fbc124b91..e852de2bc 100644 --- a/code/nel/tools/misc/log_analyser/CMakeLists.txt +++ b/code/nel/tools/misc/log_analyser/CMakeLists.txt @@ -8,4 +8,4 @@ NL_ADD_RUNTIME_FLAGS(log_analyser) ADD_DEFINITIONS(${MFC_DEFINITIONS}) -INSTALL(TARGETS log_analyser RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS log_analyser RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/log_analyser_plug_ins/extract_warnings/CMakeLists.txt b/code/nel/tools/misc/log_analyser_plug_ins/extract_warnings/CMakeLists.txt index 5524f1012..9fc570623 100644 --- a/code/nel/tools/misc/log_analyser_plug_ins/extract_warnings/CMakeLists.txt +++ b/code/nel/tools/misc/log_analyser_plug_ins/extract_warnings/CMakeLists.txt @@ -8,4 +8,4 @@ NL_ADD_RUNTIME_FLAGS(extract_warnings) NL_ADD_LIB_SUFFIX(extract_warnings) -INSTALL(TARGETS extract_warnings RUNTIME DESTINATION bin LIBRARY DESTINATION lib/log_analyser COMPONENT toolsmisc) +INSTALL(TARGETS extract_warnings RUNTIME DESTINATION ${NL_BIN_PREFIX} LIBRARY DESTINATION lib/log_analyser COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/make_sheet_id/CMakeLists.txt b/code/nel/tools/misc/make_sheet_id/CMakeLists.txt index 2b5da139e..553f7fddb 100644 --- a/code/nel/tools/misc/make_sheet_id/CMakeLists.txt +++ b/code/nel/tools/misc/make_sheet_id/CMakeLists.txt @@ -8,5 +8,5 @@ TARGET_LINK_LIBRARIES(make_sheet_id nelmisc) NL_DEFAULT_PROPS(make_sheet_id "NeL, Tools, Misc: make_sheet_id") NL_ADD_RUNTIME_FLAGS(make_sheet_id) -INSTALL(TARGETS make_sheet_id RUNTIME DESTINATION bin COMPONENT toolsmisc) -INSTALL(FILES make_sheet_id.cfg DESTINATION etc/nel COMPONENT toolsmisc) +INSTALL(TARGETS make_sheet_id RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) +INSTALL(FILES make_sheet_id.cfg DESTINATION ${NL_ETC_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/message_box/CMakeLists.txt b/code/nel/tools/misc/message_box/CMakeLists.txt index 8aec80959..764071d9d 100644 --- a/code/nel/tools/misc/message_box/CMakeLists.txt +++ b/code/nel/tools/misc/message_box/CMakeLists.txt @@ -6,4 +6,4 @@ ADD_EXECUTABLE(message_box WIN32 ${SRC}) NL_DEFAULT_PROPS(message_box "NeL, Tools, Misc: message_box") NL_ADD_RUNTIME_FLAGS(message_box) -INSTALL(TARGETS message_box RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS message_box RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/message_box_qt/CMakeLists.txt b/code/nel/tools/misc/message_box_qt/CMakeLists.txt index f71143341..408bf867e 100644 --- a/code/nel/tools/misc/message_box_qt/CMakeLists.txt +++ b/code/nel/tools/misc/message_box_qt/CMakeLists.txt @@ -14,5 +14,5 @@ NL_ADD_RUNTIME_FLAGS(message_box_qt) ADD_DEFINITIONS(${QT_DEFINITIONS}) -INSTALL(TARGETS message_box_qt RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS message_box_qt RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/multi_cd_setup_fix/CMakeLists.txt b/code/nel/tools/misc/multi_cd_setup_fix/CMakeLists.txt index 550547cce..3a5f7da4e 100644 --- a/code/nel/tools/misc/multi_cd_setup_fix/CMakeLists.txt +++ b/code/nel/tools/misc/multi_cd_setup_fix/CMakeLists.txt @@ -6,4 +6,4 @@ ADD_EXECUTABLE(multi_cd_setup_fix WIN32 ${SRC} multi_cd_setup_fix.rc) NL_DEFAULT_PROPS(multi_cd_setup_fix "NeL, Tools, Misc: multi_cd_setup_fix") NL_ADD_RUNTIME_FLAGS(multi_cd_setup_fix) -INSTALL(TARGETS multi_cd_setup_fix RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS multi_cd_setup_fix RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/probe_timers/CMakeLists.txt b/code/nel/tools/misc/probe_timers/CMakeLists.txt index df0f34926..cb17490df 100644 --- a/code/nel/tools/misc/probe_timers/CMakeLists.txt +++ b/code/nel/tools/misc/probe_timers/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(nl_probe_timers nelmisc) NL_DEFAULT_PROPS(nl_probe_timers "NeL, Tools, Misc: Probe Timers") NL_ADD_RUNTIME_FLAGS(nl_probe_timers) -INSTALL(TARGETS nl_probe_timers RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS nl_probe_timers RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/words_dic/CMakeLists.txt b/code/nel/tools/misc/words_dic/CMakeLists.txt index 1769422e5..c3f3975f2 100644 --- a/code/nel/tools/misc/words_dic/CMakeLists.txt +++ b/code/nel/tools/misc/words_dic/CMakeLists.txt @@ -12,4 +12,4 @@ IF(WITH_PCH) ADD_NATIVE_PRECOMPILED_HEADER(words_dic ${CMAKE_CURRENT_SOURCE_DIR}/StdAfx.h ${CMAKE_CURRENT_SOURCE_DIR}/StdAfx.cpp) ENDIF(WITH_PCH) -INSTALL(TARGETS words_dic RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS words_dic RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/words_dic_qt/CMakeLists.txt b/code/nel/tools/misc/words_dic_qt/CMakeLists.txt index dcfb2a9f6..2f755dfc1 100644 --- a/code/nel/tools/misc/words_dic_qt/CMakeLists.txt +++ b/code/nel/tools/misc/words_dic_qt/CMakeLists.txt @@ -27,6 +27,6 @@ NL_ADD_RUNTIME_FLAGS(words_dic_qt) ADD_DEFINITIONS(${QT_DEFINITIONS}) -INSTALL(TARGETS words_dic_qt RUNTIME DESTINATION bin COMPONENT toolsmisc) -INSTALL(FILES words_dic.cfg DESTINATION etc/nel COMPONENT toolsmisc) +INSTALL(TARGETS words_dic_qt RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) +INSTALL(FILES words_dic.cfg DESTINATION ${NL_ETC_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/misc/xml_packer/CMakeLists.txt b/code/nel/tools/misc/xml_packer/CMakeLists.txt index 70d5a3270..c9dcd4c6b 100644 --- a/code/nel/tools/misc/xml_packer/CMakeLists.txt +++ b/code/nel/tools/misc/xml_packer/CMakeLists.txt @@ -6,4 +6,4 @@ TARGET_LINK_LIBRARIES(xml_packer nelmisc) NL_DEFAULT_PROPS(xml_packer "NeL, Tools, Misc: xml_packer") NL_ADD_RUNTIME_FLAGS(xml_packer) -INSTALL(TARGETS xml_packer RUNTIME DESTINATION bin COMPONENT toolsmisc) +INSTALL(TARGETS xml_packer RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolsmisc) diff --git a/code/nel/tools/nel_unit_test/CMakeLists.txt b/code/nel/tools/nel_unit_test/CMakeLists.txt index 5b2f2d0d4..8c53ff1c6 100644 --- a/code/nel/tools/nel_unit_test/CMakeLists.txt +++ b/code/nel/tools/nel_unit_test/CMakeLists.txt @@ -10,4 +10,4 @@ NL_ADD_RUNTIME_FLAGS(nel_unit_test) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS} -DNEL_UNIT_BASE="${PROJECT_SOURCE_DIR}/tools/nel_unit_test/") -INSTALL(TARGETS nel_unit_test RUNTIME DESTINATION bin) +INSTALL(TARGETS nel_unit_test RUNTIME DESTINATION ${NL_BIN_PREFIX}) diff --git a/code/nel/tools/pacs/build_ig_boxes/CMakeLists.txt b/code/nel/tools/pacs/build_ig_boxes/CMakeLists.txt index 6700863af..fb2feedbe 100644 --- a/code/nel/tools/pacs/build_ig_boxes/CMakeLists.txt +++ b/code/nel/tools/pacs/build_ig_boxes/CMakeLists.txt @@ -8,5 +8,5 @@ TARGET_LINK_LIBRARIES(build_ig_boxes nelmisc nelpacs nel3d) NL_DEFAULT_PROPS(build_ig_boxes "NeL, Tools, PACS: build_ig_boxes") NL_ADD_RUNTIME_FLAGS(build_ig_boxes) -INSTALL(TARGETS build_ig_boxes RUNTIME DESTINATION bin COMPONENT toolspacs) -INSTALL(FILES build_ig_boxes.cfg DESTINATION etc/nel COMPONENT toolspacs) +INSTALL(TARGETS build_ig_boxes RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolspacs) +INSTALL(FILES build_ig_boxes.cfg DESTINATION ${NL_ETC_PREFIX} COMPONENT toolspacs) diff --git a/code/nel/tools/pacs/build_indoor_rbank/CMakeLists.txt b/code/nel/tools/pacs/build_indoor_rbank/CMakeLists.txt index ff23551c0..85f1984bf 100644 --- a/code/nel/tools/pacs/build_indoor_rbank/CMakeLists.txt +++ b/code/nel/tools/pacs/build_indoor_rbank/CMakeLists.txt @@ -8,5 +8,5 @@ TARGET_LINK_LIBRARIES(build_indoor_rbank nelmisc nelpacs) NL_DEFAULT_PROPS(build_indoor_rbank "NeL, Tools, PACS: build_indoor_rbank") NL_ADD_RUNTIME_FLAGS(build_indoor_rbank) -INSTALL(TARGETS build_indoor_rbank RUNTIME DESTINATION bin COMPONENT toolspacs) -INSTALL(FILES build_indoor_rbank.cfg DESTINATION etc/nel COMPONENT toolspacs) +INSTALL(TARGETS build_indoor_rbank RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolspacs) +INSTALL(FILES build_indoor_rbank.cfg DESTINATION ${NL_ETC_PREFIX} COMPONENT toolspacs) diff --git a/code/nel/tools/pacs/build_rbank/CMakeLists.txt b/code/nel/tools/pacs/build_rbank/CMakeLists.txt index f16cfb407..b35cb808c 100644 --- a/code/nel/tools/pacs/build_rbank/CMakeLists.txt +++ b/code/nel/tools/pacs/build_rbank/CMakeLists.txt @@ -12,5 +12,5 @@ NL_ADD_RUNTIME_FLAGS(build_rbank) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) -INSTALL(TARGETS build_rbank RUNTIME DESTINATION bin COMPONENT toolspacs) -INSTALL(FILES build_rbank.cfg DESTINATION etc/nel COMPONENT toolspacs) +INSTALL(TARGETS build_rbank RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolspacs) +INSTALL(FILES build_rbank.cfg DESTINATION ${NL_ETC_PREFIX} COMPONENT toolspacs) diff --git a/code/nel/tools/sound/build_samplebank/CMakeLists.txt b/code/nel/tools/sound/build_samplebank/CMakeLists.txt index e53b54e11..ab427373c 100644 --- a/code/nel/tools/sound/build_samplebank/CMakeLists.txt +++ b/code/nel/tools/sound/build_samplebank/CMakeLists.txt @@ -10,4 +10,4 @@ TARGET_LINK_LIBRARIES(build_samplebank nelmisc nelsound) NL_DEFAULT_PROPS(build_samplebank "NeL, Tools, Sound: build_samplebank") NL_ADD_RUNTIME_FLAGS(build_samplebank) -INSTALL(TARGETS build_samplebank RUNTIME DESTINATION bin COMPONENT toolssound) +INSTALL(TARGETS build_samplebank RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolssound) diff --git a/code/nel/tools/sound/build_sound/CMakeLists.txt b/code/nel/tools/sound/build_sound/CMakeLists.txt index 5549e4284..7813e4e8f 100644 --- a/code/nel/tools/sound/build_sound/CMakeLists.txt +++ b/code/nel/tools/sound/build_sound/CMakeLists.txt @@ -10,4 +10,4 @@ TARGET_LINK_LIBRARIES(build_sound nelmisc nelsound) NL_DEFAULT_PROPS(build_sound "NeL, Tools, Sound: build_sound") NL_ADD_RUNTIME_FLAGS(build_sound) -INSTALL(TARGETS build_sound RUNTIME DESTINATION bin COMPONENT toolssound) +INSTALL(TARGETS build_sound RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolssound) diff --git a/code/nel/tools/sound/build_soundbank/CMakeLists.txt b/code/nel/tools/sound/build_soundbank/CMakeLists.txt index 27148ed26..4431a47b8 100644 --- a/code/nel/tools/sound/build_soundbank/CMakeLists.txt +++ b/code/nel/tools/sound/build_soundbank/CMakeLists.txt @@ -10,4 +10,4 @@ TARGET_LINK_LIBRARIES(build_soundbank nelmisc nelsound) NL_DEFAULT_PROPS(build_soundbank "NeL, Tools, Sound: build_soundbank") NL_ADD_RUNTIME_FLAGS(build_soundbank) -INSTALL(TARGETS build_soundbank RUNTIME DESTINATION bin COMPONENT toolssound) +INSTALL(TARGETS build_soundbank RUNTIME DESTINATION ${NL_BIN_PREFIX} COMPONENT toolssound) diff --git a/code/nelns/admin_executor_service/CMakeLists.txt b/code/nelns/admin_executor_service/CMakeLists.txt index 25749af66..620c1a78a 100644 --- a/code/nelns/admin_executor_service/CMakeLists.txt +++ b/code/nelns/admin_executor_service/CMakeLists.txt @@ -14,4 +14,4 @@ NL_ADD_RUNTIME_FLAGS(admin_executor_service) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) INSTALL(TARGETS admin_executor_service RUNTIME DESTINATION sbin COMPONENT aes) -INSTALL(FILES admin_executor_service.cfg common.cfg DESTINATION etc/nel/nelns COMPONENT aes) +INSTALL(FILES admin_executor_service.cfg common.cfg DESTINATION ${NL_ETC_PREFIX}/nelns COMPONENT aes) diff --git a/code/nelns/admin_service/CMakeLists.txt b/code/nelns/admin_service/CMakeLists.txt index 88d5aaeb9..a7eee50a1 100644 --- a/code/nelns/admin_service/CMakeLists.txt +++ b/code/nelns/admin_service/CMakeLists.txt @@ -17,4 +17,4 @@ NL_ADD_RUNTIME_FLAGS(admin_service) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) INSTALL(TARGETS admin_service RUNTIME DESTINATION sbin COMPONENT as) -INSTALL(FILES admin_service.cfg common.cfg DESTINATION etc/nel/nelns COMPONENT as) +INSTALL(FILES admin_service.cfg common.cfg DESTINATION ${NL_ETC_PREFIX}/nelns COMPONENT as) diff --git a/code/nelns/login_service/CMakeLists.txt b/code/nelns/login_service/CMakeLists.txt index 5ae88df7c..1ee7260fe 100644 --- a/code/nelns/login_service/CMakeLists.txt +++ b/code/nelns/login_service/CMakeLists.txt @@ -17,4 +17,4 @@ NL_ADD_RUNTIME_FLAGS(login_service) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) INSTALL(TARGETS login_service RUNTIME DESTINATION sbin COMPONENT ls) -INSTALL(FILES login_service.cfg common.cfg DESTINATION etc/nel/nelns COMPONENT ls) +INSTALL(FILES login_service.cfg common.cfg DESTINATION ${NL_ETC_PREFIX}/nelns COMPONENT ls) diff --git a/code/nelns/login_system/nel_launcher_qt/CMakeLists.txt b/code/nelns/login_system/nel_launcher_qt/CMakeLists.txt index 3bd503eef..7e128f1b7 100644 --- a/code/nelns/login_system/nel_launcher_qt/CMakeLists.txt +++ b/code/nelns/login_system/nel_launcher_qt/CMakeLists.txt @@ -37,5 +37,5 @@ INSTALL(TARGETS nel_launcher_qt RUNTIME DESTINATION bin COMPONENT launcher) IF(WIN32) INSTALL(FILES nel_launcher.cfg DESTINATION bin COMPONENT launcher) ELSE(WIN32) - INSTALL(FILES nel_launcher.cfg DESTINATION etc/nel/nelns COMPONENT launcher) + INSTALL(FILES nel_launcher.cfg DESTINATION ${NL_ETC_PREFIX}/nelns COMPONENT launcher) ENDIF(WIN32) diff --git a/code/nelns/login_system/nel_launcher_windows_ext2/CMakeLists.txt b/code/nelns/login_system/nel_launcher_windows_ext2/CMakeLists.txt index 79093faef..f139252b8 100644 --- a/code/nelns/login_system/nel_launcher_windows_ext2/CMakeLists.txt +++ b/code/nelns/login_system/nel_launcher_windows_ext2/CMakeLists.txt @@ -20,4 +20,4 @@ IF(WITH_PCH) ENDIF(WITH_PCH) INSTALL(TARGETS nel_launcher_ext2 RUNTIME DESTINATION bin COMPONENT launcher) -INSTALL(FILES nel_launcher.cfg DESTINATION etc/nel COMPONENT launcher) +INSTALL(FILES nel_launcher.cfg DESTINATION ${NL_ETC_PREFIX} COMPONENT launcher) diff --git a/code/nelns/naming_service/CMakeLists.txt b/code/nelns/naming_service/CMakeLists.txt index 4073d1193..9616ca957 100644 --- a/code/nelns/naming_service/CMakeLists.txt +++ b/code/nelns/naming_service/CMakeLists.txt @@ -15,4 +15,4 @@ NL_ADD_RUNTIME_FLAGS(naming_service) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) INSTALL(TARGETS naming_service RUNTIME DESTINATION sbin COMPONENT ns) -INSTALL(FILES naming_service.cfg common.cfg DESTINATION etc/nel/nelns COMPONENT ns) +INSTALL(FILES naming_service.cfg common.cfg DESTINATION ${NL_ETC_PREFIX}/nelns COMPONENT ns) diff --git a/code/nelns/welcome_service/CMakeLists.txt b/code/nelns/welcome_service/CMakeLists.txt index e25c08a0c..c6819d97d 100644 --- a/code/nelns/welcome_service/CMakeLists.txt +++ b/code/nelns/welcome_service/CMakeLists.txt @@ -15,4 +15,4 @@ NL_ADD_RUNTIME_FLAGS(welcome_service) ADD_DEFINITIONS(${LIBXML2_DEFINITIONS}) INSTALL(TARGETS welcome_service RUNTIME DESTINATION sbin COMPONENT ws) -INSTALL(FILES welcome_service.cfg common.cfg DESTINATION etc/nel/nelns COMPONENT ws) +INSTALL(FILES welcome_service.cfg common.cfg DESTINATION ${NL_ETC_PREFIX}/nelns COMPONENT ws) diff --git a/code/ryzom/client/client_default.cfg b/code/ryzom/client/client_default.cfg index 311b7cddd..f95a5c2b6 100644 --- a/code/ryzom/client/client_default.cfg +++ b/code/ryzom/client/client_default.cfg @@ -476,7 +476,7 @@ XMLR2EDInterfaceFiles = { "r2ed.xml", "r2_triggers.xml", - "r2_logic_entities.xml", + "r2_logic_entities.xml", "r2ed_acts.xml", "r2ed_scenario.xml", "r2ed_connect.xml" @@ -560,11 +560,11 @@ HelpPages = "de=http://forums.ryzom.com/forum/showthread.php?t=29131" }; -WebIgMainDomain = "atys.ryzom.com"; +WebIgMainDomain = "app.ryzom.com"; WebIgTrustedDomains = { - "atys.ryzom.com" + "api.ryzom.com", "app.ryzom.com" }; -PatchletUrl = "http://atys.ryzom.com/start/app_patchlet.php?patch=preload"; +PatchletUrl = "http://app.ryzom.com/app_patchlet/index.php?patch=preload"; SelectedSlot = 0; diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/actions.xml b/code/ryzom/client/data/gamedev/interfaces_v3/actions.xml index 4596702eb..3486e0298 100644 --- a/code/ryzom/client/data/gamedev/interfaces_v3/actions.xml +++ b/code/ryzom/client/data/gamedev/interfaces_v3/actions.xml @@ -39,7 +39,8 @@ - + + diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/commands.xml b/code/ryzom/client/data/gamedev/interfaces_v3/commands.xml index 821225a03..6fdb5d32a 100644 --- a/code/ryzom/client/data/gamedev/interfaces_v3/commands.xml +++ b/code/ryzom/client/data/gamedev/interfaces_v3/commands.xml @@ -63,6 +63,9 @@ + + + @@ -88,6 +91,11 @@ + + + + + diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/config.xml b/code/ryzom/client/data/gamedev/interfaces_v3/config.xml index c2fa6a71f..630ecd4c6 100644 --- a/code/ryzom/client/data/gamedev/interfaces_v3/config.xml +++ b/code/ryzom/client/data/gamedev/interfaces_v3/config.xml @@ -318,6 +318,12 @@ + + @@ -3389,6 +3395,10 @@ This MUST follow the Enum MISSION_DESC::TIconId + + diff --git a/code/ryzom/client/data/gamedev/interfaces_v3/game_config.xml b/code/ryzom/client/data/gamedev/interfaces_v3/game_config.xml index 560d471ff..0a5c3c085 100644 --- a/code/ryzom/client/data/gamedev/interfaces_v3/game_config.xml +++ b/code/ryzom/client/data/gamedev/interfaces_v3/game_config.xml @@ -18,7 +18,7 @@ color="255 255 255 255" fontsize="14" shadow="true" - case_mode="%case_first_string_letter_up" /> + case_mode="%case_normal" />