Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AppVeyor: building and testing Poco with VS2013 and CMake/CTest #1072

Merged
merged 50 commits into from
Dec 13, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
42b317b
Add ws2_32.lib
zosrothko Dec 8, 2015
19b3974
Install also CppUnit for running tests later on.
zosrothko Dec 9, 2015
b564f2f
Build using cmake without some components whose dependencies are not …
zosrothko Dec 9, 2015
09ecc0a
Display ${CMAKE_CONFIGURATION_TYPES} & ${CMAKE_BUILD_TYPE}
zosrothko Dec 9, 2015
120bad0
Use Win32OpenSSL-1_0_2e.exe
zosrothko Dec 9, 2015
ceb1b7a
Use Visual Studio 12 2013 generator.
zosrothko Dec 9, 2015
d776595
Use ctest.
zosrothko Dec 9, 2015
f7d2bed
Remove cd ..
zosrothko Dec 9, 2015
f02c653
Exclude Data* tests.
zosrothko Dec 9, 2015
ccc4cb9
Exclude DataODBC and DataMySQL
zosrothko Dec 9, 2015
09c884e
Exclude all Data*
zosrothko Dec 9, 2015
963136a
Add trap -p before running the matrix
zosrothko Dec 10, 2015
6fdb6aa
Add display of trapped signals.
zosrothko Dec 10, 2015
93f7fbf
Restore "arm-linux-gnueabi- (make)" test since config/Linux does not add
zosrothko Dec 10, 2015
3b7ef1e
Workaround the trap '' SIGINT from Travis until Travis solve by itself.
zosrothko Dec 10, 2015
4f3d524
Remove travis_wait()
zosrothko Dec 10, 2015
9547517
Workaround to avoid Travis timeout: display progress messages on cout.
zosrothko Dec 10, 2015
5fbe817
Cannot reset inherited trap control in a subshell.
zosrothko Dec 10, 2015
df5d63f
Fix per mikedld on the trap '' SIGINT issue when using bash wait.
zosrothko Dec 10, 2015
3d029ea
Merge remote-tracking branch 'pocoproject@github/develop' into develop
zosrothko Dec 10, 2015
0bb0361
Use Clock instead of Timestamp which is inaccurate on multicode CPU.
zosrothko Dec 11, 2015
b1f6767
Use the environment variable opensll for the version to download.
zosrothko Dec 11, 2015
0e6f735
Merge remote-tracking branch 'pocoproject@github/develop' into develop
zosrothko Dec 11, 2015
5048f2a
Build Release before Debug.
zosrothko Dec 11, 2015
70d40dc
First OSX try.
zosrothko Dec 11, 2015
abc11d8
Travis does not like ':' in variable value
zosrothko Dec 11, 2015
48a7bc5
Protect Linux commands by testing TRAVIS_OS_NAME
zosrothko Dec 11, 2015
8ed8f78
Comply to YAML syntax....
zosrothko Dec 11, 2015
ed90ed7
Again YAML...
zosrothko Dec 11, 2015
1ee27b3
OSX: --omit=Data/ODBC,Data/MySQL,Data/SQLite
zosrothko Dec 11, 2015
e355715
Add #travischannel for Slack. Remove all trap -p; DO make install for
zosrothko Dec 11, 2015
9fb5053
Remove testProxy temporarely for completion of AppVeyor CI for now.
zosrothko Dec 11, 2015
4e6bdab
Merge remote-tracking branch 'pocoproject@github/develop' into develop
zosrothko Dec 11, 2015
07ba367
Merge remote-tracking branch 'pocoproject@github/develop' into develop
zosrothko Dec 11, 2015
76a87e9
Exckude Zip/CompressTest/testZip64 for now, it takes too much time to
zosrothko Dec 11, 2015
4027a05
Reformat
zosrothko Dec 12, 2015
735689c
Remove the suffix() from TestLibrary path.
zosrothko Dec 12, 2015
48df5ef
Remove the "d" suffix for TestApp binary.
zosrothko Dec 12, 2015
ae51e05
Fis eol
zosrothko Dec 12, 2015
2c601fd
Restore suffix for TestLibrary.
zosrothko Dec 12, 2015
a348c86
Add debug option -d
zosrothko Dec 12, 2015
3f1b573
No 'd' suffix for TestApp whatever the link mode release or debug
zosrothko Dec 12, 2015
2f3230f
use VS macro instead of hard literal.
zosrothko Dec 12, 2015
f161423
Add building of TestApp & TestLibrary
zosrothko Dec 12, 2015
7c432c1
Add build of TestApp & TestLibrary when component is Foundation
zosrothko Dec 12, 2015
d15d8a6
Exclude from the Debug build temporarly for AppVeyor stability.To be …
zosrothko Dec 13, 2015
9039ae6
Merge remote-tracking branch 'pocoproject@github/develop' into develop
zosrothko Dec 13, 2015
f58dfc7
Fix typo.
zosrothko Dec 13, 2015
d927b28
Exclude from the Debug build temporarly for AppVeyor stability. To be…
zosrothko Dec 13, 2015
537b181
Don't build static link mode for TestLibrary project.
zosrothko Dec 13, 2015
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 27 additions & 20 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,11 @@ before_install:
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then wget --no-check-certificate https://www.cmake.org/files/v3.2/cmake-3.2.3-Linux-x86_64.tar.gz; fi
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then tar -xzvf cmake-3.2.3-Linux-x86_64.tar.gz; fi
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then export PATH=$PWD/cmake-3.2.3-Linux-x86_64/bin:$PATH; fi
- sudo apt-get update -qq
- sudo apt-get install -qq -y unixodbc-dev libmysqlclient-dev libsqlite3-dev
- sudo apt-get install -qq -y g++-arm-linux-gnueabi g++-arm-linux-gnueabihf clang-3.5
- sudo apt-get install -qq -y sloccount cppcheck
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get update -qq; fi
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get install -qq -y unixodbc-dev libmysqlclient-dev libsqlite3-dev; fi
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get install -qq -y g++-arm-linux-gnueabi g++-arm-linux-gnueabihf clang-3.5; fi
- if [ "$TRAVIS_OS_NAME" == "linux" ]; then sudo apt-get install -qq -y sloccount cppcheck; fi


services:
- mongodb
Expand All @@ -22,8 +23,8 @@ services:
notifications:
slack:
rooms:
- pocoproject:ItIUZvs8aJGyPdaKxIKMnS1t
- kampbell:v4ARuptk0ETzwUsKDdV6Gspb#travis
- pocoproject:4iwY1QpB8fdU2WqpcZ6PpZhz#travis
- kampbell:v4ARuptk0ETzwUsKDdV6Gspb#poco

env:
global: TEST_NAME=""
Expand All @@ -34,31 +35,37 @@ before_script:

matrix:
include:
- env: TEST_NAME="gcc (make) bundled"
- env: TEST_NAME="OSX clang (make) bundled"
compiler: clang
os: osx
script:
- ./configure --everything --omit=Data/ODBC,Data/MySQL,Data/SQLite && make install -s -j2
- ./travis/runtests.sh

- env: TEST_NAME="Linux gcc (make) bundled"
compiler: gcc
script:
- ./configure --everything && make -s -j2
- travis_wait 30 ./travis/runtests.sh
- ./travis/runtests.sh

- env: TEST_NAME="gcc (make) unbundled"
- env: TEST_NAME="Linux gcc (make) unbundled"
compiler: gcc
script:
- sudo apt-get install -qq -y libpcre3-dev libssl-dev libexpat1-dev
- ./configure --everything --unbundled && make -s -j2
- travis_wait 30 ./travis/runtests.sh
- ./travis/runtests.sh

- env: TEST_NAME="clang (make)"
- env: TEST_NAME="Linux clang (make)"
compiler: clang
script:
- ./configure --everything --config=Linux-clang && make -s -j2
- travis_wait 30 ./travis/runtests.sh
- ./travis/runtests.sh

#FIXME the -m64 option bring by the Linux config is not supported by arm-linux-gnueabi-g++ which makes this test failing
#FIXME - env: TEST_NAME="arm-linux-gnueabi- (make)"
#FIXME script:
#FIXME - ./configure --omit=Data/ODBC,Data/MySQL,Crypto,NetSSL,PageCompiler && make -s -j2 CROSS_COMPILE=arm-linux-gnueabi- POCO_TARGET_OSARCH=armv7l
- env: TEST_NAME="Linux arm-linux-gnueabi- (make)"
script:
- ./configure --omit=Data/ODBC,Data/MySQL,Crypto,NetSSL,PageCompiler && make -s -j2 CROSS_COMPILE=arm-linux-gnueabi- POCO_TARGET_OSARCH=armv7l

- env: TEST_NAME="gcc (CMake)"
- env: TEST_NAME="Linux gcc (CMake)"
compiler: gcc
script:
# disable tests, gcc-4.6 gets an internal compiler error
Expand All @@ -74,18 +81,18 @@ matrix:
- export CXX="g++-4.8"
- mkdir cmake-build && cd cmake-build && cmake -DENABLE_TESTS=ON .. && make -j2 && cd ..

- env: TEST_NAME="clang (CMake)"
- env: TEST_NAME="Linux clang (CMake)"
compiler: clang
script:
- mkdir cmake-build && cd cmake-build && cmake -DENABLE_TESTS=ON .. && make -j2 && cd ..

- env: TEST_NAME="arm-linux-gnueabi-g++ (CMake)"
- env: TEST_NAME="Linux arm-linux-gnueabi-g++ (CMake)"
script:
- export CC="arm-linux-gnueabi-gcc"
- export CXX="arm-linux-gnueabi-g++"
- mkdir cmake-build && cd cmake-build && cmake -DENABLE_NETSSL=OFF -DENABLE_CRYPTO=OFF -DENABLE_TESTS=ON .. && make -j2 && cd ..

- env: TEST_NAME="arm-linux-gnueabihf-g++ (CMake)"
- env: TEST_NAME="Linux arm-linux-gnueabihf-g++ (CMake)"
script:
- export CC="arm-linux-gnueabihf-gcc"
- export CXX="arm-linux-gnueabihf-g++"
Expand Down
6 changes: 5 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@ if(NOT MSVC_IDE)
set(CMAKE_BUILD_TYPE RelWithDebInfo CACHE STRING
"Choose the type of build, options are: None Debug Release" FORCE)
endif()
message(STATUS "Setting Poco build type - ${CMAKE_BUILD_TYPE}")
endif()

if (CMAKE_BUILD_TYPE STREQUAL "")
Expand Down Expand Up @@ -279,6 +278,11 @@ install(
message(STATUS "CMake ${CMAKE_VERSION} successfully configured ${PROJECT_NAME} using ${CMAKE_GENERATOR} generator")
message(STATUS "Installation target path: ${CMAKE_INSTALL_PREFIX}")

message(STATUS "")
message(STATUS "Generated with config types: ${CMAKE_CONFIGURATION_TYPES}")
message(STATUS "Setting Poco build type - ${CMAKE_BUILD_TYPE}")
message(STATUS "")

message(STATUS "C_FLAGS: =${CMAKE_C_FLAGS}")
message(STATUS "CMAKE_C_FLAGS_DEBUG:=${CMAKE_C_FLAGS_DEBUG}")
message(STATUS "CMAKE_C_FLAGS_RELEASE:=${CMAKE_C_FLAGS_RELEASE}")
Expand Down
2 changes: 2 additions & 0 deletions CppUnit/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,5 @@ target_include_directories( "${LIBNAME}"
PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/src
)
target_compile_definitions("${LIBNAME}" PUBLIC ${LIB_MODE_DEFINITIONS})

SIMPLE_INSTALL(${LIBNAME})
10 changes: 6 additions & 4 deletions Foundation/testsuite/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,17 @@ else()
add_executable( TestApp src/TestApp.cpp )
endif()
# The test is run in the runtime directory. So the TestApp is built there too because it is used by the tests
set_target_properties( TestApp PROPERTIES DEBUG_POSTFIX "") # don't use DEBUG_POSTFIX ${CMAKE_DEBUG_POSTFIX}
set_target_properties( TestApp PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} )
target_link_libraries( TestApp PocoFoundation )
target_link_libraries( TestApp PocoFoundation)

if(NOT POCO_STATIC)
# TestLibrary
add_library( TestLibrary SHARED src/TestLibrary.cpp src/TestPlugin.cpp src/TestPlugin.h )
set_target_properties( TestLibrary PROPERTIES PREFIX "" DEBUG_POSTFIX "") # The test requires the library named TestLibrary. By default it is prefixed with lib.
# The test is run in the runtime directory. So the TestLibrary is built there too because it is used by the tests
# The test requires the library named TestLibrary. By default it is prefixed with lib.
set_target_properties( TestLibrary PROPERTIES PREFIX "" DEBUG_POSTFIX "") # don't use DEBUG_POSTFIX ${CMAKE_DEBUG_POSTFIX}
set_target_properties( TestLibrary PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} )
target_link_libraries( TestLibrary PocoFoundation )
target_link_libraries( TestLibrary PocoFoundation)

endif()

22 changes: 11 additions & 11 deletions Foundation/testsuite/TestApp_vs120.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -118,9 +118,9 @@
<IntDir Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">obj\TestApp\$(Configuration)\</IntDir>
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">false</LinkIncremental>
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'">TestApp</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">TestAppd</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">TestAppd</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">TestAppd</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">TestApp</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'">TestApp</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'">TestApp</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'">TestApp</TargetName>
<TargetName Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'">TestApp</TargetName>
</PropertyGroup>
Expand All @@ -143,10 +143,10 @@
<AdditionalOptions>/FS</AdditionalOptions>
</ClCompile>
<Link>
<OutputFile>bin\TestAppd.exe</OutputFile>
<OutputFile>%(OutputFile)</OutputFile>
<AdditionalLibraryDirectories>..\..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<GenerateDebugInformation>true</GenerateDebugInformation>
<ProgramDatabaseFile>bin\TestAppd.pdb</ProgramDatabaseFile>
<ProgramDatabaseFile>bin\$(TargetName).pdb</ProgramDatabaseFile>
<SubSystem>Console</SubSystem>
<TargetMachine>MachineX86</TargetMachine>
</Link>
Expand Down Expand Up @@ -174,7 +174,7 @@
<AdditionalOptions>/FS</AdditionalOptions>
</ClCompile>
<Link>
<OutputFile>bin\TestApp.exe</OutputFile>
<OutputFile>%(OutputFile)</OutputFile>
<AdditionalLibraryDirectories>..\..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<GenerateDebugInformation>false</GenerateDebugInformation>
<ProgramDatabaseFile>
Expand Down Expand Up @@ -208,7 +208,7 @@
<AdditionalOptions>/FS</AdditionalOptions>
</ClCompile>
<Link>
<OutputFile>bin\static_md\TestApp.exe</OutputFile>
<OutputFile>%(OutputFile)</OutputFile>
<AdditionalLibraryDirectories>..\..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<GenerateDebugInformation>false</GenerateDebugInformation>
<ProgramDatabaseFile>
Expand Down Expand Up @@ -238,7 +238,7 @@
<AdditionalOptions>/FS</AdditionalOptions>
</ClCompile>
<Link>
<OutputFile>bin\static_md\TestAppd.exe</OutputFile>
<OutputFile>%(OutputFile)</OutputFile>
<AdditionalLibraryDirectories>..\..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<GenerateDebugInformation>true</GenerateDebugInformation>
<ProgramDatabaseFile>bin\static_md\TestAppd.pdb</ProgramDatabaseFile>
Expand All @@ -265,10 +265,10 @@
<AdditionalOptions>/FS</AdditionalOptions>
</ClCompile>
<Link>
<OutputFile>bin\static_mt\TestAppd.exe</OutputFile>
<OutputFile>%(OutputFile)</OutputFile>
<AdditionalLibraryDirectories>..\..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<GenerateDebugInformation>true</GenerateDebugInformation>
<ProgramDatabaseFile>bin\static_mt\TestAppd.pdb</ProgramDatabaseFile>
<ProgramDatabaseFile>bin\static_mt\$(TargetName).pdb</ProgramDatabaseFile>
<SubSystem>Console</SubSystem>
<TargetMachine>MachineX86</TargetMachine>
</Link>
Expand Down Expand Up @@ -296,7 +296,7 @@
<AdditionalOptions>/FS</AdditionalOptions>
</ClCompile>
<Link>
<OutputFile>bin\static_mt\TestApp.exe</OutputFile>
<OutputFile>%(OutputFile)</OutputFile>
<AdditionalLibraryDirectories>..\..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<GenerateDebugInformation>false</GenerateDebugInformation>
<ProgramDatabaseFile>
Expand Down
4 changes: 2 additions & 2 deletions Foundation/testsuite/TestLibrary_vs120.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,10 @@
</ClCompile>
<Link>
<AdditionalDependencies>PocoFoundationd.lib;%(AdditionalDependencies)</AdditionalDependencies>
<OutputFile>bin\TestLibraryd.dll</OutputFile>
<OutputFile>%(OutputFile)</OutputFile>
<AdditionalLibraryDirectories>..\..\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<GenerateDebugInformation>true</GenerateDebugInformation>
<ProgramDatabaseFile>bin\TestLibraryd.pdb</ProgramDatabaseFile>
<ProgramDatabaseFile>bin\$(TargetName).pdb</ProgramDatabaseFile>
<SubSystem>Console</SubSystem>
<ImportLibrary>
</ImportLibrary>
Expand Down
Loading