1
0
mirror of https://github.com/gnss-sdr/gnss-sdr synced 2024-12-14 04:00:34 +00:00

Fixed GTEST_DIR env variable detector under MACOSX. Fixed small compatibility issue in armadilo norm for armadillo version < 4.100

git-svn-id: https://svn.code.sf.net/p/gnss-sdr/code/trunk@503 64b25241-fba3-4117-9849-534c7e92360d
This commit is contained in:
Javier Arribas 2014-04-07 16:20:09 +00:00
parent 4e714bf033
commit 743af3398d
3 changed files with 8 additions and 6 deletions

View File

@ -171,7 +171,7 @@ set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -O2")
# Googletest - http://code.google.com/p/googletest/
################################################################################
enable_testing()
set(GTEST_DIR $ENV{GTEST_DIR})
set(GTEST_DIR "$ENV{GTEST_DIR}")
if(GTEST_DIR)
message(STATUS "GTEST root folder at ${GTEST_DIR}")
else()

View File

@ -16,10 +16,12 @@
# along with GNSS-SDR. If not, see <http://www.gnu.org/licenses/>.
#
set(GTEST_DIR_LOCAL $ENV{GTEST_DIR})
if(NOT EXISTS GTEST_DIR_LOCAL)
set(GTEST_DIR_LOCAL "$ENV{GTEST_DIR}")
if(NOT GTEST_DIR_LOCAL)
set(GTEST_DIR_LOCAL false)
endif(NOT EXISTS GTEST_DIR_LOCAL)
else()
set(GTEST_DIR_LOCAL true)
endif(NOT GTEST_DIR_LOCAL)
if(NOT GTEST_DIR_LOCAL)

View File

@ -89,7 +89,7 @@ TEST(Multiply_Test, ArmadilloImplementation)
<< "-length double Armadillo vectors finished in " << (end - begin)
<< " microseconds" << std::endl;
ASSERT_LE(0, end - begin);
ASSERT_EQ(0, arma::norm(output));
ASSERT_EQ(0, arma::norm(output,2));
}
@ -173,7 +173,7 @@ TEST(Multiply_Test, ArmadilloComplexImplementation)
<< "-length complex float Armadillo vectors finished in " << (end - begin)
<< " microseconds" << std::endl;
ASSERT_LE(0, end - begin);
ASSERT_EQ(0, arma::norm(output));
ASSERT_EQ(0, arma::norm(output,2));
}