export CC=gcc
export CXX=g++
git clean -fxd . # Only do this in the build folder
- autoreconf --install
- CXXFLAGS='-g -O0 --coverage' LDFLAGS='--coverage' ./configure --prefix=$DESKTOP_PREFIX --enable-debug
+ CXXFLAGS='-g -O0 --coverage' LDFLAGS='--coverage' cmake -DCMAKE_INSTALL_PREFIX=$DESKTOP_PREFIX -DCMAKE_BUILD_TYPE=Debug
make -j8 install
-Repeat for dali-adaptor and toolkit.
-
Note, you __must__ use a local build and not a distributed build, and you __must__ also build with debug enabled to allow *DALI_ASSERT_DEBUG* to trigger on wrong behaviour ( Which should always be a test case failure! )
Building the tests
#!/usr/bin/perl
-# Copyright (c) 2018 Samsung Electronics Co., Ltd.
+# Copyright (c) 2019 Samsung Electronics Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You can then source this script by using
# \$ . setenv
#
-# Use DESKTOP_PREFIX when running configure in dali/build/tizen:
+# Use DESKTOP_PREFIX when running configure or cmake in dali/build/tizen:
# \$ CXXFLAGS="-g -O0" ./configure --prefix=\$DESKTOP_PREFIX
+# _OR_
+# \$ CXXFLAGS="-g -O0" cmake -DCMAKE_INSTALL_PREFIX=\$DESKTOP_PREFIX
export DESKTOP_PREFIX=$install_path
export PATH=$install_path/bin:\$PATH
IF(CMAKE_BUILD_TYPE MATCHES Debug)
MESSAGE( STATUS "CMAKE_BUILD_TYPE: " Debug )
- SET(ENABLE_DEBUG ON)
+ SET( ENABLE_DEBUG ON )
ELSE()
MESSAGE( STATUS "CMAKE_BUILD_TYPE: " Release )
ENDIF()
ADD_DEFINITIONS("-DTARGET")
ENDIF("${ARCH}" STREQUAL "arm")
-IF( NOT ${ENABLE_EXPORTALL} AND NOT ${ENABLE_DEBUG} )
- ADD_DEFINITIONS( "-fvisibility=hidden -DHIDE_DALI_INTERNALS" )
-ENDIF( NOT ${ENABLE_EXPORTALL} AND NOT ${ENABLE_DEBUG} )
-
IF( ENABLE_DEBUG )
ADD_DEFINITIONS( "-DDEBUG_ENABLED" )
+ SET( ENABLE_EXPORTALL ON )
ENDIF( ENABLE_DEBUG )
+IF( NOT ${ENABLE_EXPORTALL} )
+ ADD_DEFINITIONS( "-fvisibility=hidden -DHIDE_DALI_INTERNALS" )
+ENDIF( NOT ${ENABLE_EXPORTALL} )
+
IF( ENABLE_BACKTRACE OR ENABLE_LOCK_BACKTRACE )
ADD_DEFINITIONS( "-DBACKTRACE_ENABLED" )
ENDIF( ENABLE_BACKTRACE OR ENABLE_LOCK_BACKTRACE )
MESSAGE( STATUS "Lib Dir: " ${LIB_DIR} )
MESSAGE( STATUS "Include Dir: " ${INCLUDE_DIR} )
MESSAGE( STATUS "Debug build: " ${ENABLE_DEBUG} )
+MESSAGE( STATUS "Export all symbols: " ${ENABLE_EXPORTALL} )
MESSAGE( STATUS "Backtrace: " ${ENABLE_BACKTRACE} )
MESSAGE( STATUS "Scoped Lock backtrace: " ${ENABLE_LOCK_BACKTRACE} )
MESSAGE( STATUS "Coverage: " ${ENABLE_COVERAGE} )
/*
* Definitions for shared library support.
*
- * If a library is configured with --enable-exportall or --enable-debug
+ * If a library is built with -DENABLE_EXPORTALL=ON or -DENABLE_DEBUG=ON
* then HIDE_DALI_INTERNALS is not defined, and nothing is hidden.
- * If it is configured without these options (the default), then HIDE_INTERNALS
+ * If it is built without these options (the default), then HIDE_INTERNALS
* is defined when building the library, visibility is automatically hidden, and the explicit
* defines below come into use.
* When building a library that uses DALI, HIDE_DALI_INTERNALS.