From 1e2910a5cf0f90fe780d78a02c1b7b074e622961 Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Thu, 17 Dec 2015 02:21:48 +0000 Subject: Use definedDirs improvements to fix test behaviour --- slicer/test/fileStructure.cpp | 11 ++++------- slicer/test/fileStructure.h | 4 ++-- 2 files changed, 6 insertions(+), 9 deletions(-) diff --git a/slicer/test/fileStructure.cpp b/slicer/test/fileStructure.cpp index 0d27ce1..53b3c2d 100644 --- a/slicer/test/fileStructure.cpp +++ b/slicer/test/fileStructure.cpp @@ -1,16 +1,13 @@ #include "fileStructure.h" #include #include - -#define XSTR(s) STR(s) -#define STR(s) #s -const boost::filesystem::path root(XSTR(ROOT)); +#include FileStructure::FileStructure() : - me(boost::filesystem::canonical("/proc/self/exe")), + me(selfExe), base("types"), - bjamout("bin" / me.parent_path().parent_path().leaf() / me.parent_path().leaf()), - root(::root), + bjamout("bin" / buildVariant), + root(rootDir), included(root / "included"), slice(fs::change_extension(root / base, ".ice")), tmp(root / "bin" / "slicer") diff --git a/slicer/test/fileStructure.h b/slicer/test/fileStructure.h index ac38637..e19f95c 100644 --- a/slicer/test/fileStructure.h +++ b/slicer/test/fileStructure.h @@ -11,10 +11,10 @@ class FileStructure { ~FileStructure(); protected: - const fs::path me; + const fs::path & me; const fs::path base; const fs::path bjamout; - const fs::path root; + const fs::path & root; const fs::path included; const fs::path slice; const fs::path tmp; -- cgit v1.2.3