Skip to content

Commit 807e0fc

Browse files
committed
Added Ci/CD target and removed CycloneDDS dependency
1 parent 569a56c commit 807e0fc

File tree

6 files changed

+156
-42
lines changed

6 files changed

+156
-42
lines changed

CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
cmake_minimum_required(VERSION 3.7)
55

66
# Set module path before defining project so platform files will work.
7+
include(${CMAKE_ROOT}/Modules/ExternalProject.cmake)
78
list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_LIST_DIR}/idlpp/cmake/modules)
89
set(CMAKE_PROJECT_NAME_FULL "CXX Idl compiler for Eclipse CycloneDDS")
910
set(PROJECT_NAME "Idlpp-cxx")

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ This project provides an idl compiler to compile datatypes that can be used in t
77
In order to build the Idl compiler you need a Linux, Mac or Windows 10 machine with the following
88
installed on your host:
99

10-
* [CycloneDDS](https://github.com/eclipse-cyclonedds/cyclonedds/)
10+
* Git
1111
* [CMake](https://cmake.org/download/), version 3.7 or later. (Version 3.6 should work but you
1212
will have to edit the ``cmake_minimum_required`` version.)
1313
* Java JDK, version 8 or later, e.g., [OpenJDK 11](http://jdk.java.net/11/).
@@ -22,15 +22,15 @@ between Linux and macOS on the one hand, and Windows on the other. For Linux or
2222
$ git clone https://github.com/ADLINK-IST/idlpp-cxx.git
2323
$ mkdir build
2424
$ cd build
25-
$ cmake -DCycloneDDS_DIR="path to CycloneDDSConfig.cmake" <cmake-config_options> ..
25+
$ cmake <cmake-config_options> ..
2626
$ cmake --build .
2727

2828
and for Windows:
2929

3030
$ git clone https://github.com/ADLINK-IST/idlpp-cxx.git
3131
$ mkdir build
3232
$ cd build
33-
$ cmake -G "<generator-name>" -DCycloneDDS_DIR="path to CycloneDDSConfig.cmake" <cmake-config_options> ..
33+
$ cmake -G "<generator-name>" <cmake-config_options> ..
3434
$ cmake --build .
3535

3636
where you replace ``<generator-name>`` by one of the ways
@@ -61,7 +61,7 @@ This would make the build look like
6161

6262
$ mkdir build
6363
$ cd build
64-
$ cmake -DCycloneDDS_DIR="path to CycloneDDSConfig.cmake" -DCMAKE_INSTALL_PREFIX=<install-location> ..
64+
$ cmake -DCMAKE_INSTALL_PREFIX=<install-location> ..
6565
$ cmake --build . --target install
6666

6767
Don't forget the generator when building on Windows.

azure-pipelines.yml

Lines changed: 103 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,103 @@
1+
resources:
2+
repositories:
3+
- repository: self
4+
5+
variables:
6+
MAVEN_CACHE_FOLDER: $(Pipeline.Workspace)/.m2/repository
7+
MAVEN_OPTS: '-Dmaven.repo.local=$(MAVEN_CACHE_FOLDER)'
8+
9+
jobs:
10+
- job: Linux
11+
pool:
12+
vmImage: 'ubuntu-16.04'
13+
strategy:
14+
matrix:
15+
Clang 6.0 Release:
16+
CC: clang
17+
CXX: clang++
18+
BuildType: Release
19+
USE_SANITIZER: none
20+
GENERATOR: "Unix Makefiles"
21+
22+
GCC 5.4 Release:
23+
BuildType: Release
24+
USE_SANITIZER: none
25+
GENERATOR: "Unix Makefiles"
26+
steps:
27+
- task: UsePythonVersion@0
28+
inputs:
29+
versionSpec: '3.7'
30+
- template: build.yml
31+
32+
- job: Windows_VS19
33+
pool:
34+
vmImage: 'windows-2019'
35+
strategy:
36+
matrix:
37+
x86_64 Release:
38+
BuildType: Release
39+
GENERATOR: "Visual Studio 16 2019"
40+
USE_SANITIZER: none
41+
42+
steps:
43+
- task: UsePythonVersion@0
44+
inputs:
45+
versionSpec: '3.7'
46+
- template: build.yml
47+
48+
- job: Windows_VS17
49+
pool:
50+
vmImage: 'vs2017-win2016'
51+
strategy:
52+
matrix:
53+
x86_64 Release:
54+
BuildType: Release
55+
GENERATOR: "Visual Studio 15 2017 Win64"
56+
USE_SANITIZER: none
57+
58+
steps:
59+
- task: UsePythonVersion@0
60+
inputs:
61+
versionSpec: '3.7'
62+
- template: build.yml
63+
64+
65+
- job: MacOS_10_13
66+
pool:
67+
vmImage: 'macOS-10.13'
68+
strategy:
69+
matrix:
70+
Release Xcode 10.0:
71+
BuildType: Release
72+
USE_SANITIZER: none
73+
GENERATOR: "Unix Makefiles"
74+
steps:
75+
- task: UsePythonVersion@0
76+
inputs:
77+
versionSpec: '3.7'
78+
- script: |
79+
sudo /usr/libexec/ApplicationFirewall/socketfilterfw --setglobalstate off
80+
- template: build.yml
81+
82+
- job: MacOS_10_14
83+
pool:
84+
vmImage: 'macOS-10.14'
85+
strategy:
86+
matrix:
87+
Release Xcode 11.0:
88+
BuildType: Release
89+
USE_SANITIZER: none
90+
GENERATOR: "Unix Makefiles"
91+
steps:
92+
- task: UsePythonVersion@0
93+
inputs:
94+
versionSpec: '3.7'
95+
- bash: |
96+
/bin/bash -c "sudo xcode-select -s /Applications/Xcode_11.app/Contents/Developer"
97+
clang --version
98+
displayName: 'Set Xcode11 as default'
99+
failOnStderr: false
100+
- script: |
101+
sudo /usr/libexec/ApplicationFirewall/socketfilterfw --setglobalstate off
102+
- template: build.yml
103+

build.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
steps:
2+
- task: CacheBeta@0
3+
inputs:
4+
key: maven
5+
path: $(MAVEN_CACHE_FOLDER)
6+
displayName: Cache Maven local repo
7+
- bash: |
8+
mkdir build
9+
cd build
10+
- task: CMake@1
11+
displayName: 'CMake configure core product'
12+
inputs:
13+
cmakeArgs: '-DCMAKE_BUILD_TYPE=$(BuildType)
14+
-DCMAKE_INSTALL_PREFIX=$(Build.SourcesDirectory)/build/install
15+
-DUSE_SANITIZER=$(USE_SANITIZER)
16+
-G "$(GENERATOR)" ..'
17+
- bash: |
18+
case "$(GENERATOR)" in
19+
"Unix Makefiles")
20+
cmake --build . --config $(BuildType) --target install -- -j 4
21+
;;
22+
"Visual Studio "*)
23+
cmake --build . --config $(BuildType) --target install -- -nologo -verbosity:minimal -maxcpucount -p:CL_MPCount=2
24+
;;
25+
*)
26+
cmake --build . --config $(BuildType) --target install
27+
;;
28+
esac
29+
workingDirectory: build
30+
failOnStderr: false
31+
displayName: 'Compile'
32+
- script: |
33+
cmake --build . --config $(BuildType) --target package
34+
workingDirectory: build
35+
failOnStderr: false
36+
displayName: 'Create installer'
37+
- task: CopyFiles@2
38+
inputs:
39+
sourceFolder: '$(Build.SourcesDirectory)'
40+
targetFolder: '$(Build.ArtifactStagingDirectory)'
41+
contents: 'build/?(*.deb|*.msi|*.tar.gz|*.tar|*.zip|*.sh)'
42+
displayName: 'Copy installer'
43+
- task: PublishBuildArtifacts@1
44+
inputs:
45+
pathtoPublish: '$(Build.ArtifactStagingDirectory)'
46+
artifactName: idlpp_$(AGENT.JOBNAME)
47+
displayName: 'Publish installer'
48+

idlpp/CMakeLists.txt

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,6 @@
11
#
22
# Copyright(c) 2006 to 2019 ADLINK Technology Limited and others
33
#
4-
find_package(CycloneDDS REQUIRED)
5-
if(NOT CycloneDDS_FOUND)
6-
message(WARNING "Could not find Eclipse Cyclone DDS - skipping '${CMAKE_PROJECT_NAME}'")
7-
return()
8-
endif()
9-
104

115
# Some locations.
126
set(IDLPP_OSPLI "${CMAKE_CURRENT_SOURCE_DIR}/ppresources/ospli")

idlpp/cmake/modules/FindCycloneDDS.cmake

Lines changed: 0 additions & 32 deletions
This file was deleted.

0 commit comments

Comments
 (0)