From 12b47dc73a54e89e0f7ded02faf7d0485b6a31af Mon Sep 17 00:00:00 2001 From: Christian Muck Date: Wed, 8 Feb 2012 10:33:54 +0100 Subject: Set automatic dlt lib version number from project CMakeLists.txt. Removed dlt-test-internal because has no functionality. --- automotive-dlt.spec.in | 1 - src/lib/CMakeLists.txt | 2 +- src/tests/CMakeLists.txt | 10 +-- src/tests/dlt-test-internal.c | 186 ------------------------------------------ 4 files changed, 2 insertions(+), 197 deletions(-) delete mode 100755 src/tests/dlt-test-internal.c diff --git a/automotive-dlt.spec.in b/automotive-dlt.spec.in index aeb2b93..3a0ec8f 100644 --- a/automotive-dlt.spec.in +++ b/automotive-dlt.spec.in @@ -79,7 +79,6 @@ rm -rf $RPM_BUILD_ROOT %{_bindir}/dlt-test-stress %{_bindir}/dlt-test-stress-client %{_bindir}/dlt-test-stress-user -%{_bindir}/dlt-test-internal %{_bindir}/dlt-test-filetransfer %{_bindir}/dlt-test-multi-process %{_bindir}/dlt-test-multi-process-client diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt index 2da1b70..a916683 100755 --- a/src/lib/CMakeLists.txt +++ b/src/lib/CMakeLists.txt @@ -45,7 +45,7 @@ ENDIF(GPROF_DLT_LIB) target_link_libraries(dlt rt ${CMAKE_THREAD_LIBS_INIT}) -set_target_properties(dlt PROPERTIES VERSION 2.4.2 SOVERSION 2) +set_target_properties(dlt PROPERTIES VERSION ${PRINT_MAJOR_VERSION}.${PRINT_MINOR_VERSION}.${PRINT_PATCH_LEVEL} SOVERSION ${PRINT_MAJOR_VERSION}) install(TARGETS dlt LIBRARY DESTINATION lib diff --git a/src/tests/CMakeLists.txt b/src/tests/CMakeLists.txt index 477c4d9..a9add6e 100755 --- a/src/tests/CMakeLists.txt +++ b/src/tests/CMakeLists.txt @@ -91,14 +91,6 @@ ENDIF(GPROF_DLT_TESTS) target_link_libraries(dlt-test-stress dlt) set_target_properties(dlt-test-stress PROPERTIES LINKER_LANGUAGE C) -set(dlt_test_internal_SRCS dlt-test-internal) -add_executable(dlt-test-internal ${dlt_test_internal_SRCS}) -IF(GPROF_DLT_TESTS) - SET(CMAKE_C_FLAGS "-pg") -ENDIF(GPROF_DLT_TESTS) -target_link_libraries(dlt-test-internal dlt) -set_target_properties(dlt-test-internal PROPERTIES LINKER_LANGUAGE C) - set(dlt_test_filetransfer_SRCS dlt-test-filetransfer) add_executable(dlt-test-filetransfer ${dlt_test_filetransfer_SRCS}) IF(GPROF_DLT_TESTS) @@ -107,7 +99,7 @@ ENDIF(GPROF_DLT_TESTS) target_link_libraries(dlt-test-filetransfer dlt) set_target_properties(dlt-test-filetransfer PROPERTIES LINKER_LANGUAGE C) -install(TARGETS dlt-test-multi-process dlt-test-multi-process-client dlt-test-user dlt-test-client dlt-test-stress-user dlt-test-stress-client dlt-test-stress dlt-test-internal dlt-test-filetransfer +install(TARGETS dlt-test-multi-process dlt-test-multi-process-client dlt-test-user dlt-test-client dlt-test-stress-user dlt-test-stress-client dlt-test-stress dlt-test-filetransfer RUNTIME DESTINATION bin COMPONENT base) diff --git a/src/tests/dlt-test-internal.c b/src/tests/dlt-test-internal.c deleted file mode 100755 index c716905..0000000 --- a/src/tests/dlt-test-internal.c +++ /dev/null @@ -1,186 +0,0 @@ -/* - * Dlt Client test utilities - Diagnostic Log and Trace - * @licence app begin@ - * - * Copyright (C) 2011, BMW AG - Alexander Wenzel - * - * This program is free software; you can redistribute it and/or modify it under the terms of the - * GNU Lesser General Public License, version 2.1, as published by the Free Software Foundation. - * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even - * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General - * Public License, version 2.1, for more details. - * - * You should have received a copy of the GNU Lesser General Public License, version 2.1, along - * with this program; if not, see . - * - * Note that the copyright holders assume that the GNU Lesser General Public License, version 2.1, may - * also be applicable to programs even in cases in which the program is not a library in the technical sense. - * - * Linking DLT statically or dynamically with other modules is making a combined work based on DLT. You may - * license such other modules under the GNU Lesser General Public License, version 2.1. If you do not want to - * license your linked modules under the GNU Lesser General Public License, version 2.1, you - * may use the program under the following exception. - * - * As a special exception, the copyright holders of DLT give you permission to combine DLT - * with software programs or libraries that are released under any license unless such a combination is not - * permitted by the license of such a software program or library. You may copy and distribute such a - * system following the terms of the GNU Lesser General Public License, version 2.1, including this - * special exception, for DLT and the licenses of the other code concerned. - * - * Note that people who make modified versions of DLT are not obligated to grant this special exception - * for their modified versions; it is their choice whether to do so. The GNU Lesser General Public License, - * version 2.1, gives permission to release a modified version without this exception; this exception - * also makes it possible to release a modified version which carries forward this exception. - * - * @licence end@ - */ - - -/******************************************************************************* -** ** -** SRC-MODULE: dlt-test-internal.c ** -** ** -** TARGET : linux ** -** ** -** PROJECT : DLT ** -** ** -** AUTHOR : Alexander Wenzel Alexander.AW.Wenzel@bmw.de ** -** Markus Klein ** -** ** -** PURPOSE : ** -** ** -** REMARKS : ** -** ** -** PLATFORM DEPENDANT [yes/no]: yes ** -** ** -** TO BE CHANGED BY USER [yes/no]: no ** -** ** -*******************************************************************************/ - -/******************************************************************************* -** Author Identity ** -******************************************************************************** -** ** -** Initials Name Company ** -** -------- ------------------------- ---------------------------------- ** -** aw Alexander Wenzel BMW ** -** mk Markus Klein Fraunhofer ESK ** -*******************************************************************************/ - -/******************************************************************************* -** Revision Control History ** -*******************************************************************************/ - -/* - * $LastChangedRevision: 1670 $ - * $LastChangedDate: 2011-04-08 15:12:06 +0200 (Fr, 08. Apr 2011) $ - * $LastChangedBy$ - Initials Date Comment - aw 08.10.2010 initial - */ - -#include /* for isprint() */ -#include /* for printf() and fprintf() */ -#include /* for atoi() and exit() */ -#include /* for memset() */ - -#include "dlt.h" -#include "dlt_common.h" /* for dlt_get_version() */ - -#define MAX_TESTS 1 - -int vflag = 0; -int tests_passed = 0; -int tests_failed = 0; - -void internal1(void); - -/** - * Print usage information of tool. - */ -void usage() -{ - char version[255]; - - dlt_get_version(version); - - printf("Usage: dlt-test-internal [options]\n"); - printf("Test application executing several internal tests.\n"); - printf("%s \n", version); - printf("Options:\n"); - printf(" -v Verbose mode\n"); -} - -/** - * Main function of tool. - */ -int main(int argc, char* argv[]) -{ - int test[MAX_TESTS]; - - int i,c,help; - - for (i=0;i