Changeset 3345 for code/branches/resource
- Timestamp:
- Jul 24, 2009, 9:31:31 PM (15 years ago)
- Location:
- code/branches/resource
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/resource/cmake/Media.cmake
r2721 r3345 45 45 ################ Installation ################# 46 46 47 # Try no to copy both tcl script file libraries48 IF(TCL_LIBRARY MATCHES "85|8\\.5")49 SET(TCL_EXCLUDE_PATTERN "tcl8\\.4")50 ELSEIF(TCL_LIBRARY MATCHES "84|8\\.4")51 SET(TCL_EXCLUDE_PATTERN "tcl8\\.5")52 ENDIF()53 54 47 INSTALL( 55 48 DIRECTORY ${CMAKE_MEDIA_OUTPUT_DIRECTORY}/ 56 49 DESTINATION ${ORXONOX_MEDIA_INSTALL_PATH} 57 REGEX "\\.svn$|_svn$|backToPNG |${TCL_EXCLUDE_PATTERN}" EXCLUDE50 REGEX "\\.svn$|_svn$|backToPNG" EXCLUDE 58 51 ) -
code/branches/resource/cmake/PackageConfig.cmake
r3344 r3345 45 45 LIST(APPEND CMAKE_INCLUDE_PATH ${DEP_INCLUDE_DIR}/zlib-1.2.3/include) 46 46 47 SET(TCL_LIBRARY_DIR ${DEPENDENCY_PACKAGE_DIR}/tcl) 47 ### INSTALL ### 48 48 49 ### INSTALL ### 49 # Tcl script library 50 INSTALL( 51 DIRECTORY ${DEP_LIBRARY_DIR}/tcl/ 52 DESTINATION lib/tcl 53 ) 54 50 55 # On Windows, DLLs have to be in the executable folder, install them 51 56 IF(WIN32 AND DEP_BINARY_DIR) -
code/branches/resource/src/SpecialConfig.h.in
r3344 r3345 88 88 const char ORXONOX_LOG_DEV_PATH[] = "@CMAKE_LOG_OUTPUT_DIRECTORY@"; 89 89 #endif 90 #ifdef DEPENDENCY_PACKAGE_ENABLE 91 const char ORXONOX_DEP_LIB_PATH[] = "@DEP_LIBRARY_DIR@"; 92 #endif 90 93 91 / * OGRE Plugins */94 // OGRE PLUGINS 92 95 #ifdef NDEBUG 93 96 const char ORXONOX_OGRE_PLUGINS[] = "@OGRE_PLUGINS_RELEASE@"; … … 105 108 # endif 106 109 #endif 107 108 /* Tcl */109 #ifdef DEPENDENCY_PACKAGE_ENABLE110 const char ORXONOX_TCL_LIBRARY_PATH[] = "@TCL_LIBRARY_DIR@";111 #endif112 110 } 113 111 -
code/branches/resource/src/core/Core.cc
r3343 r3345 231 231 232 232 Core::Core(const std::string& cmdLine) 233 : bGraphicsLoaded_(false) 233 : bDevRun_(false) 234 , bGraphicsLoaded_(false) 234 235 { 235 236 if (singletonRef_s != 0) … … 435 436 } 436 437 438 /*static*/ const boost::filesystem::path& Core::getRootPath() 439 { 440 return getInstance().configuration_->rootPath_; 441 } 442 /*static*/ std::string Core::getRootPathString() 443 { 444 return getInstance().configuration_->rootPath_.string() + '/'; 445 } 446 437 447 /** 438 448 @note … … 544 554 { 545 555 COUT(1) << "Running from the build tree." << std::endl; 546 Core:: isDevBuild_ = true;556 Core::bDevRun_ = true; 547 557 configuration_->mediaPath_ = ORXONOX_MEDIA_DEV_PATH; 548 558 configuration_->configPath_ = ORXONOX_CONFIG_DEV_PATH; -
code/branches/resource/src/core/Core.h
r3343 r3345 90 90 //! Returns the path to the log files as boost::filesystem::path 91 91 static const boost::filesystem::path& getLogPath(); 92 //! Returns the path to the root folder as boost::filesystem::path 93 static const boost::filesystem::path& getRootPath(); 92 94 //! Returns the path to the data files as std::string 93 95 static std::string getMediaPathString(); … … 96 98 //! Returns the path to the log files as std::string 97 99 static std::string getLogPathString(); 100 //! Returns the path to the root folder as std::string 101 static std::string getRootPathString(); 102 103 static bool isDevelopmentRun() { return getInstance().bDevRun_; } 98 104 99 105 private: … … 114 120 TclThreadManager* tclThreadManager_; 115 121 116 bool isDevBuild_; //!< True for builds in the build directory (not installed)122 bool bDevRun_; //!< True for runs in the build directory (not installed) 117 123 bool bGraphicsLoaded_; 118 124 CoreConfiguration* configuration_; -
code/branches/resource/src/core/TclBind.cc
r3344 r3345 33 33 #include <cpptcl/cpptcl.h> 34 34 35 #include "SpecialConfig.h" 35 36 #include "util/Debug.h" 36 37 #include "util/StringUtils.h" 37 38 #include "CommandExecutor.h" 38 39 #include "ConsoleCommand.h" 40 #include "Core.h" 39 41 #include "TclThreadManager.h" 40 #include "SpecialConfig.h"41 42 42 43 namespace orxonox … … 102 103 Tcl::interpreter* TclBind::createTclInterpreter() 103 104 { 105 Tcl::interpreter* interpreter; 104 106 #ifdef DEPENDENCY_PACKAGE_ENABLE 105 Tcl::interpreter* interpreter = new Tcl::interpreter(ORXONOX_TCL_LIBRARY_PATH); 107 if (true)//Core::isDevelopmentRun()) 108 interpreter = new Tcl::interpreter(std::string(ORXONOX_DEP_LIB_PATH) + "/tcl"); 109 else 110 interpreter = new Tcl::interpreter(Core::getRootPathString() + "lib/tcl"); 106 111 #else 107 Tcl::interpreter*interpreter = new Tcl::interpreter();112 interpreter = new Tcl::interpreter(); 108 113 #endif 109 114 try 110 115 { 111 interpreter->eval("source " + TclBind::getInstance().tclDataPath_ + "/init.tcl");116 interpreter->eval("source \"" + TclBind::getInstance().tclDataPath_ + "/init.tcl\""); 112 117 } 113 118 catch (Tcl::tcl_error const &e)
Note: See TracChangeset
for help on using the changeset viewer.