Skip to content

Commit

Permalink
Update to .NET 8 with a complete review of the folder structure (#74)
Browse files Browse the repository at this point in the history
* Update location of .NET project

* Java folder rename

* rename folder to jvm to be compliant with other repository

* Moved C\C++ code into native folder

* Moved folder under src

* Moved submodules under src folder

* Moved other source files under src

* Update description

* Update OpenDDS to 3.29.1

* Workflow and versions alignment

* Docs update
  • Loading branch information
masesdevelopers authored Oct 1, 2024
1 parent 3b1041c commit 2150b49
Show file tree
Hide file tree
Showing 269 changed files with 461 additions and 363 deletions.
7 changes: 1 addition & 6 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,7 @@ updates:
directory: "/src/DataDistributionManagerNet" # Location of package manifests
schedule:
interval: "weekly"

- package-ecosystem: "gitsubmodule"
directory: "/"
schedule:
interval: weekly


- package-ecosystem: "github-actions"
directory: "/"
schedule:
Expand Down
151 changes: 79 additions & 72 deletions .github/workflows/build.yaml

Large diffs are not rendered by default.

18 changes: 14 additions & 4 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,22 @@ name: "CodeQL"

on:
push:
branches: [ "master" ]
branches:
- master
- release/**
paths-ignore:
- 'docs/**'
pull_request:
# The branches below must be a subset of the branches above
branches: [ "master" ]
schedule:
- cron: '32 19 * * 1'
branches:
- master
- release/**
paths-ignore:
- 'docs/**'

concurrency:
group: '${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}'
cancel-in-progress: true

jobs:
analyze:
Expand Down
140 changes: 74 additions & 66 deletions .github/workflows/pullrequest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,16 @@ name: CI_PULLREQUEST
# events but only for the master branch
on:
pull_request:
branches: [ master ]

branches:
- master
- release/**
paths-ignore:
- 'docs/**'

concurrency:
group: '${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}'
cancel-in-progress: true

jobs:
# Verify if a build is needed
check_opendds:
Expand All @@ -25,7 +33,7 @@ jobs:
lookup-only: true
enableCrossOsArchive: true
path: ./OutputOpenDDS/
key: OpenDDS_3.25
key: OpenDDS_3.29.1

- name: If failed we need to rebuild artifact
id: check_existsOpenDDS
Expand Down Expand Up @@ -57,88 +65,88 @@ jobs:
- name: Configure OpenDDS
shell: cmd
run: |
cd third_party\OpenDDS
cd src\3rdparty\OpenDDS
configure
- name: Build OpenDDS x64
shell: cmd
run: |
cd third_party\OpenDDS
cd src\3rdparty\OpenDDS
call setenv.cmd
msbuild -p:Configuration=Release,Platform=x64 -m DDS_TAOv2.sln
- name: Move OpenDDS x64 binaries
shell: cmd
run: |
cd third_party\OpenDDS
xcopy .\lib\*.dll ..\..\Output\x64\
xcopy .\lib\*.lib ..\..\Output\lib64\
xcopy .\bin\*.exe ..\..\Output\bin64\
xcopy .\ACE_wrappers\lib\*.dll ..\..\Output\x64\
xcopy .\ACE_wrappers\lib\*.lib ..\..\Output\lib64\
xcopy .\ACE_wrappers\bin\*.exe ..\..\Output\bin64\
cd src\3rdparty\OpenDDS
xcopy .\lib\*.dll ..\..\..\Output\x64\
xcopy .\lib\*.lib ..\..\..\Output\lib64\
xcopy .\bin\*.exe ..\..\..\Output\bin64\
xcopy .\ACE_wrappers\lib\*.dll ..\..\..\Output\x64\
xcopy .\ACE_wrappers\lib\*.lib ..\..\..\Output\lib64\
xcopy .\ACE_wrappers\bin\*.exe ..\..\..\Output\bin64\
- name: Move OpenDDS x64 PDB
shell: cmd
run: |
cd third_party\OpenDDS
cd src\3rdparty\OpenDDS
mkdir ..\..\OutputPdb
xcopy .\lib\*.pdb ..\..\OutputPdb\pdb64\
xcopy .\bin\*.pdb ..\..\OutputPdb\pdb64\
xcopy .\ACE_wrappers\lib\*.pdb ..\..\OutputPdb\pdb64\
xcopy .\ACE_wrappers\bin\*.pdb ..\..\OutputPdb\pdb64\
xcopy .\lib\*.pdb ..\..\..\OutputPdb\pdb64\
xcopy .\bin\*.pdb ..\..\..\OutputPdb\pdb64\
xcopy .\ACE_wrappers\lib\*.pdb ..\..\..\OutputPdb\pdb64\
xcopy .\ACE_wrappers\bin\*.pdb ..\..\..\OutputPdb\pdb64\
- name: Build OpenDDS x86
shell: cmd
run: |
cd third_party\OpenDDS
cd src\3rdparty\OpenDDS
call setenv.cmd
msbuild -p:Configuration=Release,Platform=Win32 -m DDS_TAOv2.sln
- name: Move OpenDDS x86 binaries
shell: cmd
run: |
cd third_party\OpenDDS
xcopy .\lib\*.dll ..\..\Output\x86\
xcopy .\lib\*.lib ..\..\Output\lib32\
xcopy .\bin\*.exe ..\..\Output\bin32\
xcopy .\ACE_wrappers\lib\*.dll ..\..\Output\x86\
xcopy .\ACE_wrappers\lib\*.lib ..\..\Output\lib32\
xcopy .\ACE_wrappers\bin\*.exe ..\..\Output\bin32\
cd src\3rdparty\OpenDDS
xcopy .\lib\*.dll ..\..\..\Output\x86\
xcopy .\lib\*.lib ..\..\..\Output\lib32\
xcopy .\bin\*.exe ..\..\..\Output\bin32\
xcopy .\ACE_wrappers\lib\*.dll ..\..\..\Output\x86\
xcopy .\ACE_wrappers\lib\*.lib ..\..\..\Output\lib32\
xcopy .\ACE_wrappers\bin\*.exe ..\..\..\Output\bin32\
- name: Move OpenDDS x86 PDB
shell: cmd
run: |
cd third_party\OpenDDS
xcopy .\lib\*.pdb ..\..\OutputPdb\pdb32\
xcopy .\bin\*.pdb ..\..\OutputPdb\pdb32\
xcopy .\ACE_wrappers\lib\*.pdb ..\..\OutputPdb\pdb32\
xcopy .\ACE_wrappers\bin\*.pdb ..\..\OutputPdb\pdb32\
cd src\3rdparty\OpenDDS
xcopy .\lib\*.pdb ..\..\..\OutputPdb\pdb32\
xcopy .\bin\*.pdb ..\..\..\OutputPdb\pdb32\
xcopy .\ACE_wrappers\lib\*.pdb ..\..\..\OutputPdb\pdb32\
xcopy .\ACE_wrappers\bin\*.pdb ..\..\..\OutputPdb\pdb32\
- name: Move setenv.cmd
shell: cmd
run: |
cd third_party\OpenDDS
xcopy setenv.cmd ..\..\Output\
cd src\3rdparty\OpenDDS
xcopy setenv.cmd ..\..\..\Output\
- name: Prepare for packaging OpenDDS Binaries and PDB
run: |
New-Item -Path .\OutputOpenDDS -ItemType directory
Compress-Archive -Path .\Output\* -DestinationPath .\OutputOpenDDS\OpenDDS_Build_3.25.zip
Compress-Archive -Path .\OutputPdb\* -DestinationPath .\OutputOpenDDS\OpenDDS_PDB_Build_3.25.zip
Compress-Archive -Path .\Output\* -DestinationPath .\OutputOpenDDS\OpenDDS_Build_3.29.1.zip
Compress-Archive -Path .\OutputPdb\* -DestinationPath .\OutputOpenDDS\OpenDDS_PDB_Build_3.29.1.zip
- name: Prepare for packaging OpenDDS Headers
shell: cmd
run: |
7z a .\OutputOpenDDS\OpenDDS_Headers_3.25.zip .\third_party\OpenDDS\*.h -r
7z u .\OutputOpenDDS\OpenDDS_Headers_3.25.zip .\third_party\OpenDDS\*.inl -r
7z a .\OutputOpenDDS\OpenDDS_Headers_3.29.1.zip .\src\3rdparty\OpenDDS\*.h -r
7z u .\OutputOpenDDS\OpenDDS_Headers_3.29.1.zip .\src\3rdparty\OpenDDS\*.inl -r
- name: Save OpenDDS in cache
uses: actions/cache/save@v4
with:
enableCrossOsArchive: true
path: ./OutputOpenDDS/
key: OpenDDS_3.25
key: OpenDDS_3.29.1

# This workflow contains a single job called "build_release"
build_pullrequest:
Expand All @@ -164,7 +172,7 @@ jobs:
- name: Build Common Tools
shell: cmd
run: |
cd third_party\CommonTools
cd src\3rdparty\CommonTools
msbuild -p:Configuration=Release,Platform="Any CPU" -m CommonTools.sln
- name: Extract commit SHA
Expand All @@ -175,15 +183,15 @@ jobs:
- name: Prepare version
shell: cmd
run: |
cd third_party\CommonTools\Output
cd src\3rdparty\CommonTools\Output
VersionGenerator %GITHUB_WORKSPACE%\src\ProductInformation\Version.cs %GITHUB_WORKSPACE%\src\ProductInformation ${{ env.GITHUB_COMMIT_MESSAGE }}
env:
GITHUB_WORKSPACE: $GITHUB_WORKSPACE

- name: Prepare nuget
shell: cmd
run: |
third_party\CommonTools\Output\PlaceHolderReplacer.exe .\src\ProductInformation\Version.cs .\packaging\nuget\datadistributionmanager.nuspec >> .\nuget_version.txt
src\3rdparty\CommonTools\Output\PlaceHolderReplacer.exe .\src\ProductInformation\Version.cs .\src\packaging\nuget\datadistributionmanager.nuspec >> .\nuget_version.txt
- name: Store version
run: |
Expand All @@ -192,14 +200,14 @@ jobs:

- name: Verify Nuget version in file
run: |
type .\packaging\nuget\datadistributionmanager.nuspec
type .\src\packaging\nuget\datadistributionmanager.nuspec
echo ${{ env.NUGET_PACKAGE_VERSION }}
shell: cmd

- name: Configure OpenDDS
shell: cmd
run: |
cd third_party\OpenDDS
cd src\3rdparty\OpenDDS
configure
- name: Restore OpenDDS from cache
Expand All @@ -208,32 +216,32 @@ jobs:
fail-on-cache-miss: true
enableCrossOsArchive: true
path: ./OutputOpenDDS/
key: OpenDDS_3.25
key: OpenDDS_3.29.1

- name: Prepare OpenDDS Binaries
run: |
Expand-Archive -LiteralPath '.\OutputOpenDDS\OpenDDS_Build_3.25.zip' -DestinationPath .\Output -Force
Expand-Archive -LiteralPath '.\OutputOpenDDS\OpenDDS_Build_3.29.1.zip' -DestinationPath .\Output -Force
- name: Prepare OpenDDS Headers
run: |
Expand-Archive -LiteralPath '.\OutputOpenDDS\OpenDDS_Headers_3.25.zip' -DestinationPath .\third_party\OpenDDS -Force
Expand-Archive -LiteralPath '.\OutputOpenDDS\OpenDDS_Headers_3.29.1.zip' -DestinationPath .\src\3rdparty\OpenDDS -Force
- name: Move OpenDDS x64
shell: cmd
run: |
xcopy .\Output\bin32\*.* .\third_party\OpenDDS\bin\
xcopy .\Output\x86\*.dll .\third_party\OpenDDS\lib\
xcopy .\Output\bin32\*.* .\third_party\OpenDDS\ACE_wrappers\bin\
xcopy .\Output\x86\*.dll .\third_party\OpenDDS\ACE_wrappers\lib\
xcopy .\Output\bin32\*.* .\src\3rdparty\OpenDDS\bin\
xcopy .\Output\x86\*.dll .\src\3rdparty\OpenDDS\lib\
xcopy .\Output\bin32\*.* .\src\3rdparty\OpenDDS\ACE_wrappers\bin\
xcopy .\Output\x86\*.dll .\src\3rdparty\OpenDDS\ACE_wrappers\lib\
- name: Generate OpenDDS projects
shell: cmd
run: |
call .\third_party\OpenDDS\setenv.cmd
cd src\DataDistributionManagerOpenDDS
call .\src\3rdparty\OpenDDS\setenv.cmd
cd src\native\DataDistributionManagerOpenDDS
perl %ACE_ROOT%\bin\generate_export_file.pl DataDistributionSchemaCommon > DataDistributionSchemaCommon_Export.h
perl %ACE_ROOT%\bin\mwc.pl -type vs2022 DataDistributionManagerOpenDDS.mwc
cd ..\..
cd ..\..\..
- uses: nuget/setup-nuget@v2.0.0
with:
Expand All @@ -243,24 +251,24 @@ jobs:
- name: Build DataDistributionManager x64
shell: cmd
run: |
call .\third_party\OpenDDS\setenv.cmd
call .\src\3rdparty\OpenDDS\setenv.cmd
set JDK_ROOT_FOLDER=%JAVA_HOME_11_X64%
cd src
msbuild /m -p:Configuration=Release,Platform=x64 DataDistributionManager.sln
- name: Build DataDistributionManager x86
shell: cmd
run: |
call .\third_party\OpenDDS\setenv.cmd
call .\src\3rdparty\OpenDDS\setenv.cmd
set JDK_ROOT_FOLDER=%JAVA_HOME_11_X64%
cd src
msbuild /m -p:Configuration=Release,Platform=Win32 DataDistributionManager.sln
- name: Build DataDistributionManager net462, net6.0 and net7.0
- name: Build DataDistributionManager net462, net6.0 and net8.0
run: |
dotnet build --no-incremental --configuration Release --framework net462 -o Output src\DataDistributionManagerNet\DataDistributionManagerNet.csproj
dotnet build --no-incremental --configuration Release --framework net6.0 -o Outputnet6.0 src\DataDistributionManagerNet\DataDistributionManagerNet.csproj
dotnet build --no-incremental --configuration Release --framework net7.0 -o Outputnet7.0 src\DataDistributionManagerNet\DataDistributionManagerNet.csproj
dotnet build --no-incremental --configuration Release --framework net462 -o Output src\net\DataDistributionManagerNet\DataDistributionManagerNet.csproj
dotnet build --no-incremental --configuration Release --framework net6.0 -o Outputnet6.0 src\net\DataDistributionManagerNet\DataDistributionManagerNet.csproj
dotnet build --no-incremental --configuration Release --framework net8.0 -o Outputnet8.0 src\net\DataDistributionManagerNet\DataDistributionManagerNet.csproj
- name: Prepare for packaging
run: |
Expand All @@ -276,10 +284,10 @@ jobs:
New-Item -Path .\OutputPackage\pdb\x64 -ItemType directory
New-Item -Path .\OutputPackage\include -ItemType directory
New-Item -Path .\OutputPackage\licenses -ItemType directory
Copy-Item .\src\DataDistributionManager\DataDistributionManagerEnums.h .\OutputPackage\include\DataDistributionManagerEnums.h
Copy-Item .\src\DataDistributionManager\DataDistributionManagerTypes.h .\OutputPackage\include\DataDistributionManagerTypes.h
Copy-Item .\src\DataDistributionManager\DataDistributionManager.h .\OutputPackage\include\DataDistributionManager.h
Copy-Item .\src\DataDistributionManager\SmartDataDistributionManager.h .\OutputPackage\include\SmartDataDistributionManager.h
Copy-Item .\src\native\DataDistributionManager\DataDistributionManagerEnums.h .\OutputPackage\include\DataDistributionManagerEnums.h
Copy-Item .\src\native\DataDistributionManager\DataDistributionManagerTypes.h .\OutputPackage\include\DataDistributionManagerTypes.h
Copy-Item .\src\native\DataDistributionManager\DataDistributionManager.h .\OutputPackage\include\DataDistributionManager.h
Copy-Item .\src\native\DataDistributionManager\SmartDataDistributionManager.h .\OutputPackage\include\SmartDataDistributionManager.h
Copy-Item .\Output\x86\DataDistributionManager.lib .\OutputPackage\lib\x86\DataDistributionManager.lib -Force
Copy-Item .\Output\x64\DataDistributionManager.lib .\OutputPackage\lib\x64\DataDistributionManager.lib -Force
Copy-Item .\Output\*.dll .\OutputPackage\runtime\ -Force
Expand All @@ -296,8 +304,8 @@ jobs:
Copy-Item .\Output\x64\*.pdb .\OutputPackage\pdb\x64\ -Force
Copy-Item .\Output\pdb64\*.pdb .\OutputPackage\pdb\x64\ -Force
Copy-Item .\LICENSE .\OutputPackage\licenses\LICENSE.datadistributionmanager -Force
Copy-Item .\src\packages\librdkafka.redist.2.2.0\LICENSES.txt .\OutputPackage\licenses\LICENSE.librdkafka -Force
Copy-Item .\third_party\OpenDDS\LICENSE .\OutputPackage\licenses\LICENSE.opendds -Force
Copy-Item .\src\packages\librdkafka.redist.2.5.3\LICENSES.txt .\OutputPackage\licenses\LICENSE.librdkafka -Force
Copy-Item .\src\3rdparty\OpenDDS\LICENSE .\OutputPackage\licenses\LICENSE.opendds -Force
Compress-Archive -Path .\OutputPackage\* -DestinationPath .\OutputPackage\DataDistributionManager.zip
- name: Prepare for Java packaging
Expand All @@ -311,12 +319,12 @@ jobs:
- name: Build Java Binder
shell: cmd
run: |
cd src\DataDistributionManagerJava
cd src\jvm
set JDK_ROOT_FOLDER=%JAVA_HOME_11_X64%
CreateJar.bat
cd ..\..
- uses: nuget/setup-nuget@v2.0.0
with:
nuget-version: '5.x'
- run: nuget pack packaging\nuget\datadistributionmanager.nuspec
- run: nuget pack src\packaging\nuget\datadistributionmanager.nuspec
Loading

0 comments on commit 2150b49

Please sign in to comment.