From 7e3eb23d133ce7576b09e8aa39ebe8fb7a8a8aa9 Mon Sep 17 00:00:00 2001 From: randomdan Date: Thu, 13 Nov 2014 23:39:54 +0000 Subject: Scattering of fixes to remove hacks around paths and fix running the build from folders other than the project root --- project2/ice/tests/Jamfile.jam | 3 +++ project2/ice/tests/testClient.cpp | 5 +++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/project2/ice/tests/Jamfile.jam b/project2/ice/tests/Jamfile.jam index 2081be6..976f34d 100644 --- a/project2/ice/tests/Jamfile.jam +++ b/project2/ice/tests/Jamfile.jam @@ -8,9 +8,12 @@ lib test : ..//pthread ; +path-constant me : . ; + unit-test testClient : [ glob testClient.cpp ] : + ROOT=\"$(me)\" test.ice ..//p2iceclient ../../ut//p2ut diff --git a/project2/ice/tests/testClient.cpp b/project2/ice/tests/testClient.cpp index 2cc3651..7cd960f 100644 --- a/project2/ice/tests/testClient.cpp +++ b/project2/ice/tests/testClient.cpp @@ -4,9 +4,10 @@ #include "iceClient.h" #include +#define XSTR(s) STR(s) +#define STR(s) #s const auto self = boost::filesystem::canonical("/proc/self/exe"); -const auto iceroot = self.parent_path().parent_path().parent_path().parent_path(); -const Glib::ustring testPlatform; +const boost::filesystem::path iceroot(XSTR(ROOT)); BOOST_AUTO_TEST_CASE( compile_client_full ) { -- cgit v1.2.3