[Liblas-commits] hg: [cmake] Added experimental rules for MSVC to
set custom PATH...
liblas-commits at liblas.org
liblas-commits at liblas.org
Tue Sep 29 15:33:29 EDT 2009
changeset e7c73ce07e62 in /home/www/liblas.org/hg
details: http://hg.liblas.org/main/hg?cmd=changeset;node=e7c73ce07e62
summary: [cmake] Added experimental rules for MSVC to set custom PATH for Debugging->Environment property in generated *.vcproj.*.user file so all run-time dependencies are found and libLAS programs can run inside IDE.
diffstat:
CMakeLists.txt | 8 ++
apps/CMakeLists.txt | 12 +++
build/cmake/libLAS.vcproj.user.template | 121 ++++++++++++++++++++++++++++++
3 files changed, 141 insertions(+), 0 deletions(-)
diffs (166 lines):
diff -r ea3f319afd55 -r e7c73ce07e62 CMakeLists.txt
--- a/CMakeLists.txt Tue Sep 29 00:36:19 2009 +0100
+++ b/CMakeLists.txt Tue Sep 29 20:33:20 2009 +0100
@@ -58,6 +58,14 @@
ADD_DEFINITIONS(-D_CRT_SECURE_NO_WARNINGS)
ADD_DEFINITIONS(-D_CRT_NONSTDC_NO_WARNING)
ENDIF()
+
+ # Generate dot-user file with user-specific settings for Visual Studio project
+ SET(MSVC_ENVIRONMENT_PATH "" CACHE STRING
+ "Custom PATH for Environment property in Visual Studio project configuration")
+ MARK_AS_ADVANCED(MSVC_ENVIRONMENT_PATH)
+ SET(VCPROJ_USER_ENVIRONMENT_PATH_DEBUG "${ENVIRONMENT_PATH}")
+ MARK_AS_ADVANCED(VCPROJ_USER_ENVIRONMENT_PATH_DEBUG)
+
ENDIF()
ELSE()
IF(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX)
diff -r ea3f319afd55 -r e7c73ce07e62 apps/CMakeLists.txt
--- a/apps/CMakeLists.txt Tue Sep 29 00:36:19 2009 +0100
+++ b/apps/CMakeLists.txt Tue Sep 29 20:33:20 2009 +0100
@@ -37,6 +37,18 @@
${LASINFO} ${LASMERGE} ${LAS2LAS} ${LAS2TXT} ${TXT2LAS}
${LAS2OGR} ${LASINDEX} ${LAS2OCI})
+# TODO: Experimental and requires testing --mloskot
+# Generate user-specific settings for Visual Studio project
+SET(VCPROJ_USER_REMOTE_MACHINE_DEBUG ${MACHINE_NAME})
+SET(VCPROJ_USER_ENVIRONMENT_DEBUG "${ENVIRONMENT_PATH}")
+
+FOREACH(utility ${LIBLAS_UTILITIES})
+ SET(USER_FILE ${utility}.vcproj.$ENV{USERDOMAIN}.$ENV{USERNAME}.user)
+ SET(OUTPUT_PATH ${CMAKE_CURRENT_BINARY_DIR}/${USER_FILE})
+ MESSAGE(STATUS "Generating ${CMAKE_GENERATOR} user-specific settings in ${USER_FILE}")
+ CONFIGURE_FILE(${CMAKE_SOURCE_DIR}/build/cmake/libLAS.vcproj.user.template ${OUTPUT_PATH} @ONLY)
+ENDFOREACH()
+
###############################################################################
# Configure build targets
diff -r ea3f319afd55 -r e7c73ce07e62 build/cmake/libLAS.vcproj.user.template
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/build/cmake/libLAS.vcproj.user.template Tue Sep 29 20:33:20 2009 +0100
@@ -0,0 +1,121 @@
+<?xml version="1.0" encoding="Windows-1252"?>
+<VisualStudioUserFile
+ ProjectType="Visual C++"
+ Version="9.00"
+ ShowAllFiles="false"
+ >
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ >
+ <DebugSettings
+ Command="$(TargetPath)"
+ WorkingDirectory=""
+ CommandArguments=""
+ Attach="false"
+ DebuggerType="3"
+ Remote="1"
+ RemoteMachine="DEV410"
+ RemoteCommand=""
+ HttpUrl=""
+ PDBPath=""
+ SQLDebugging=""
+ Environment="PATH=@VCPROJ_USER_ENVIRONMENT_PATH_DEBUG@;%PATH%"
+ EnvironmentMerge="true"
+ DebuggerFlavor="0"
+ MPIRunCommand=""
+ MPIRunArguments=""
+ MPIRunWorkingDirectory=""
+ ApplicationCommand=""
+ ApplicationArguments=""
+ ShimCommand=""
+ MPIAcceptMode=""
+ MPIAcceptFilter=""
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ >
+ <DebugSettings
+ Command="$(TargetPath)"
+ WorkingDirectory=""
+ CommandArguments=""
+ Attach="false"
+ DebuggerType="3"
+ Remote="1"
+ RemoteMachine="DEV410"
+ RemoteCommand=""
+ HttpUrl=""
+ PDBPath=""
+ SQLDebugging=""
+ Environment="PATH=@VCPROJ_USER_ENVIRONMENT_PATH_DEBUG@;%PATH%"
+ EnvironmentMerge="true"
+ DebuggerFlavor="0"
+ MPIRunCommand=""
+ MPIRunArguments=""
+ MPIRunWorkingDirectory=""
+ ApplicationCommand=""
+ ApplicationArguments=""
+ ShimCommand=""
+ MPIAcceptMode=""
+ MPIAcceptFilter=""
+ />
+ </Configuration>
+ <Configuration
+ Name="MinSizeRel|Win32"
+ >
+ <DebugSettings
+ Command="$(TargetPath)"
+ WorkingDirectory=""
+ CommandArguments=""
+ Attach="false"
+ DebuggerType="3"
+ Remote="1"
+ RemoteMachine="DEV410"
+ RemoteCommand=""
+ HttpUrl=""
+ PDBPath=""
+ SQLDebugging=""
+ Environment="PATH=@VCPROJ_USER_ENVIRONMENT_PATH_DEBUG@;%PATH%"
+ EnvironmentMerge="true"
+ DebuggerFlavor="0"
+ MPIRunCommand=""
+ MPIRunArguments=""
+ MPIRunWorkingDirectory=""
+ ApplicationCommand=""
+ ApplicationArguments=""
+ ShimCommand=""
+ MPIAcceptMode=""
+ MPIAcceptFilter=""
+ />
+ </Configuration>
+ <Configuration
+ Name="RelWithDebInfo|Win32"
+ >
+ <DebugSettings
+ Command="$(TargetPath)"
+ WorkingDirectory=""
+ CommandArguments=""
+ Attach="false"
+ DebuggerType="3"
+ Remote="1"
+ RemoteMachine="DEV410"
+ RemoteCommand=""
+ HttpUrl=""
+ PDBPath=""
+ SQLDebugging=""
+ Environment="PATH=@VCPROJ_USER_ENVIRONMENT_PATH_DEBUG@;%PATH%"
+ EnvironmentMerge="true"
+ DebuggerFlavor="0"
+ MPIRunCommand=""
+ MPIRunArguments=""
+ MPIRunWorkingDirectory=""
+ ApplicationCommand=""
+ ApplicationArguments=""
+ ShimCommand=""
+ MPIAcceptMode=""
+ MPIAcceptFilter=""
+ />
+ </Configuration>
+ </Configurations>
+</VisualStudioUserFile>
\ No newline at end of file
More information about the Liblas-commits
mailing list