From 6b48f0355f01967bcbb5905116edcda8d261f6a5 Mon Sep 17 00:00:00 2001 From: guigues Date: Mon, 3 Mar 2008 08:06:36 +0000 Subject: [PATCH] *** empty log message *** --- kernel/install/linux/bbtk-uninstall.sh | 3 ++- kernel/src/CMakeLists.txt | 6 ++++- kernel/src/bbtkConfigurationFile.cxx | 20 +++++++++----- kernel/src/bbtkFactory.cxx | 9 +++---- kernel/src/bbtkFactory.h | 12 ++++----- kernel/src/bbtkInterpreter.cxx | 36 ++++++++++++-------------- kernel/src/bbtkInterpreter.h | 10 +++---- kernel/src/bbtkWxConsole.h | 8 +++--- 8 files changed, 53 insertions(+), 51 deletions(-) diff --git a/kernel/install/linux/bbtk-uninstall.sh b/kernel/install/linux/bbtk-uninstall.sh index 8a05ef5..2c7e2bb 100644 --- a/kernel/install/linux/bbtk-uninstall.sh +++ b/kernel/install/linux/bbtk-uninstall.sh @@ -1,5 +1,5 @@ echo "****** WARNING : THIS IS A BRUTE FORCE **UNSAFE** UNINSTALLER ******" -echo "****** WILL REMOVES ALL FILES AND FOLDERS STARTING WITH bb ******" +echo "****** WILL REMOVE ALL FILES AND FOLDERS STARTING WITH bb ******" TMP=$(which bbtk-uninstall.sh|rev) TMP2=$(echo ${TMP#*/}|rev) @@ -28,4 +28,5 @@ rm -Rf ${PREFIX}/lib/bb* rm -Rf ${PREFIX}/lib/libbb* rm -Rf ${PREFIX}/include/bb* rm -Rf ${PREFIX}/share/bbtk +echo "DONE !" fi diff --git a/kernel/src/CMakeLists.txt b/kernel/src/CMakeLists.txt index 32b8cb2..b519e32 100644 --- a/kernel/src/CMakeLists.txt +++ b/kernel/src/CMakeLists.txt @@ -189,7 +189,11 @@ TARGET_LINK_LIBRARIES(bbtk ${BBTK_LINK_LIBRARIES}) #----------------------------------------------------------------------------- FILE(GLOB BBTK_HEADERS "*.h") INSTALL(FILES ${BBTK_HEADERS} DESTINATION include/bbtk) -INSTALL(TARGETS bbtk DESTINATION bin) +IF(UNIX) + INSTALL(TARGETS bbtk DESTINATION lib) +ELSE(UNIX) + INSTALL(TARGETS bbtk DESTINATION bin) +ENDIF(UNIX) #----------------------------------------------------------------------------- #----------------------------------------------------------------------------- diff --git a/kernel/src/bbtkConfigurationFile.cxx b/kernel/src/bbtkConfigurationFile.cxx index b1292ca..8181a6a 100644 --- a/kernel/src/bbtkConfigurationFile.cxx +++ b/kernel/src/bbtkConfigurationFile.cxx @@ -3,8 +3,8 @@ Program: bbtk Module: $RCSfile: bbtkConfigurationFile.cxx,v $ Language: C++ - Date: $Date: 2008/02/22 17:36:42 $ - Version: $Revision: 1.11 $ + Date: $Date: 2008/03/03 08:06:36 $ + Version: $Revision: 1.12 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See doc/license.txt or @@ -36,6 +36,7 @@ namespace bbtk /// Constructor ConfigurationFile::ConfigurationFile() { + // file separator #if defined(_WIN32) mFile_separator = "\\"; @@ -68,7 +69,6 @@ namespace bbtk bbtkMessage("Config",1," ==> prefix : '"< doc : '"< bbs : '"< rsc : '"< data : '"< package_paths; std::string libname; // full path library name diff --git a/kernel/src/bbtkFactory.h b/kernel/src/bbtkFactory.h index c5433cc..8cf02be 100644 --- a/kernel/src/bbtkFactory.h +++ b/kernel/src/bbtkFactory.h @@ -3,8 +3,8 @@ Program: bbtk Module: $RCSfile: bbtkFactory.h,v $ Language: C++ - Date: $Date: 2008/02/14 13:44:25 $ - Version: $Revision: 1.7 $ + Date: $Date: 2008/03/03 08:06:36 $ + Version: $Revision: 1.8 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See doc/license.txt or @@ -43,8 +43,7 @@ namespace bbtk Factory(); ~Factory(); - void LoadPackage( const std::string& name, - bool use_configuration_file = true ); + void LoadPackage( const std::string& name ); void UnLoadPackage( const std::string& name ); void PrintPackages(bool details = true, bool adaptors = false) const; void HelpPackage(const std::string& name, bool adaptors = false) const; @@ -139,10 +138,9 @@ namespace bbtk } } - inline void LoadPackage( const std::string& name, - bool use_configuration_file = true) + inline void LoadPackage( const std::string& name ) { - GetGlobalFactory()->LoadPackage(name,use_configuration_file); + GetGlobalFactory()->LoadPackage(name); } inline void UnLoadPackage( const std::string& name ) diff --git a/kernel/src/bbtkInterpreter.cxx b/kernel/src/bbtkInterpreter.cxx index 951c40d..c572234 100644 --- a/kernel/src/bbtkInterpreter.cxx +++ b/kernel/src/bbtkInterpreter.cxx @@ -3,8 +3,8 @@ Program: bbtk Module: $RCSfile: bbtkInterpreter.cxx,v $ $ Language: C++ - Date: $Date: 2008/02/21 07:30:20 $ - Version: $Revision: 1.36 $ + Date: $Date: 2008/03/03 08:06:36 $ + Version: $Revision: 1.37 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -300,8 +300,7 @@ Interpreter* Interpreter::mGlobalInterpreter = NULL; /** * */ - void Interpreter::InterpretFile( const std::string& filename, - bool use_configuration_file) + void Interpreter::InterpretFile( const std::string& filename ) { bbtkDebugMessageInc("Interpreter",9,"Interpreter::InterpretFile(\""<0) { @@ -563,11 +562,11 @@ void Interpreter::InterpretLine( const std::string& line, bool &insideComment ) case cInclude : if (mCommandLine) { - InterpretFile(words[1], true ); // true : better pass use_config_file + InterpretFile(words[1]); } else { - SwitchToFile(words[1], true ); // true : better pass use_config_file + SwitchToFile(words[1]); } // if 'source' was given if (words.size()==3) @@ -577,7 +576,7 @@ void Interpreter::InterpretLine( const std::string& line, bool &insideComment ) break; case cLoad: - LoadPackage(words[1], true ); // true : better pass use_config_file + LoadPackage(words[1]); break; case cUnload: @@ -728,8 +727,7 @@ void Interpreter::SplitLine ( const std::string& str, std::vector& // =================================================================================== - void Interpreter::SwitchToFile( const std::string& name, - bool use_configuration_file ) + void Interpreter::SwitchToFile( const std::string& name ) { // Note : in the following : // name : the user supplied name @@ -749,16 +747,14 @@ void Interpreter::SplitLine ( const std::string& str, std::vector& std::string pkgname; // e.g. .bbs std::vector Filenames; - if (use_configuration_file) - { - // The following is *NOT* a debug time message : - // It's a user intended message. - // Please don't remove it. - bbtkMessage("Interpreter",1, - "look for : [" << name - << "] (use_configuration_file == TRUE)" << std::endl); - script_paths = ConfigurationFile::GetInstance().Get_bbs_paths(); - } + // The following is *NOT* a debug time message : + // It's a user intended message. + // Please don't remove it. + bbtkMessage("Interpreter",1, + "look for : [" << name + << "]" << std::endl); + script_paths = ConfigurationFile::GetInstance().Get_bbs_paths(); + std::string upath; pkgname = Utilities::ExtractScriptName(name,upath); diff --git a/kernel/src/bbtkInterpreter.h b/kernel/src/bbtkInterpreter.h index 0cd00f3..124323b 100644 --- a/kernel/src/bbtkInterpreter.h +++ b/kernel/src/bbtkInterpreter.h @@ -3,8 +3,8 @@ Program: bbtk Module: $RCSfile: bbtkInterpreter.h,v $ $ Language: C++ - Date: $Date: 2008/02/12 12:55:16 $ - Version: $Revision: 1.11 $ + Date: $Date: 2008/03/03 08:06:36 $ + Version: $Revision: 1.12 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -115,8 +115,7 @@ namespace bbtk void SetDialogMode(DialogModeType t) { mExecuter->SetDialogMode(t); } /// Runs the interpretation of a file - void InterpretFile( const std::string& filename, - bool use_configuration_file=true); + void InterpretFile( const std::string& filename); /// Interprets a line (either from a file or typed interactively) void InterpretLine( const std::string& line, bool &insideComment ); @@ -133,8 +132,7 @@ namespace bbtk CommandInfoType& info ); /// Switch to the interpretation of a file - void SwitchToFile( const std::string& filename, - bool use_configuration_file=true); + void SwitchToFile( const std::string& filename ); /// Closes the currently open file void CloseCurrentFile(); diff --git a/kernel/src/bbtkWxConsole.h b/kernel/src/bbtkWxConsole.h index d457589..261f434 100644 --- a/kernel/src/bbtkWxConsole.h +++ b/kernel/src/bbtkWxConsole.h @@ -3,8 +3,8 @@ Program: bbtk Module: $RCSfile: bbtkWxConsole.h,v $ Language: C++ - Date: $Date: 2008/02/12 12:55:16 $ - Version: $Revision: 1.3 $ + Date: $Date: 2008/03/03 08:06:36 $ + Version: $Revision: 1.4 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -71,8 +71,8 @@ namespace bbtk void SetDialogMode(Interpreter::DialogModeType t) { mInterpreter->SetDialogMode(t); } /// Runs the interpretation of a file - void InterpretFile( const std::string& filename, bool use_configuration_file = true) - { mInterpreter->InterpretFile(filename,use_configuration_file); } + void InterpretFile( const std::string& filename) + { mInterpreter->InterpretFile(filename); } void OnMenuQuit(wxCommandEvent& event); void OnMenuAbout(wxCommandEvent& event); -- 2.45.1