Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/micmacIGN/micmac
Browse files Browse the repository at this point in the history
  • Loading branch information
deseilligny committed Jan 25, 2024
2 parents 2384ac8 + 08683c2 commit effee6f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 4 deletions.
15 changes: 11 additions & 4 deletions MMVII/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,12 @@ endif()
#######################################################
## Custom targets
#######################################################
if (CMAKE_GENERATOR STREQUAL "Unix Makefiles")
set(make_parallel_prefix "+")
else()
unset(make_parallel_prefix)
endif()


## distclean : clean + remove generated source files for symbolic calculus
add_custom_target(distclean
Expand All @@ -173,18 +179,19 @@ add_custom_target(distclean
VERBATIM)

## full : generate source files for symbolic calculus and recompile
set(JOE )
add_custom_target(full
COMMAND ${CMAKE_COMMAND} -E rm -rf ${mmv2_gencode_dir}
COMMAND ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --config $<CONFIG>
COMMAND ${make_parallel_prefix} ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --config $<CONFIG>
COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MMVII GenCodeSymDer
COMMAND ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --config $<CONFIG>
COMMAND ${make_parallel_prefix} ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --config $<CONFIG>
VERBATIM USES_TERMINAL)

## rebuild : distclean + full
add_custom_target(rebuild
COMMAND ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --target distclean
COMMAND ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --config $<CONFIG>
COMMAND ${make_parallel_prefix} ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --config $<CONFIG>
COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/MMVII GenCodeSymDer
COMMAND ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --config $<CONFIG>
COMMAND ${make_parallel_prefix} ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --config $<CONFIG>
VERBATIM USES_TERMINAL)

2 changes: 2 additions & 0 deletions MMVII/src/Utils/uti_string.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -584,6 +584,7 @@ void MakeBckUp(const std::string & aDir,const std::string & aNameFile,int aNbDi

void GetFilesFromDir(std::vector<std::string> & aRes,const std::string & aDir,const tNameSelector & aNS,bool OnlyRegular)
{
MMVII_INTERNAL_ASSERT_User(IsDirectory(aDir), eTyUEr::eOpenFile, aDir+" is not a directory!");
for (fs::directory_iterator itr(aDir); itr!=fs::directory_iterator(); ++itr)
{
std::string aName ( itr->path().filename().generic_string().c_str());
Expand Down Expand Up @@ -618,6 +619,7 @@ std::vector<std::string> GetSubDirFromDir(const std::string & aDir,const tNameSe
*/
void RecGetFilesFromDir( std::vector<std::string> & aRes, const std::string & aDir,tNameSelector aNS,int aLevMin, int aLevMax)
{
MMVII_INTERNAL_ASSERT_User(IsDirectory(aDir), eTyUEr::eOpenFile, aDir+" is not a directory!");
for (fs::recursive_directory_iterator itr(aDir); itr!=fs::recursive_directory_iterator(); ++itr)
{
int aLev = itr.depth();
Expand Down

0 comments on commit effee6f

Please sign in to comment.