Skip to content

Commit

Permalink
Merge pull request #2 from BastiaanOlij/studio_102_build
Browse files Browse the repository at this point in the history
Change build system to Studio 10.2
  • Loading branch information
BastiaanOlij authored Mar 13, 2022
2 parents 81d70f5 + 9db2f2e commit afe63f4
Show file tree
Hide file tree
Showing 45 changed files with 336 additions and 3,753 deletions.
111 changes: 111 additions & 0 deletions .github/workflows/build_on_push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,111 @@


# Workflow to automatically compile a Linux/Windows library on commit/push
name: Build on push

# Controls when the action will run. Triggers the workflow on push or pull request
# events, but only for the master branch we'll create .zip files
on:
[push, pull_request]

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This job builds the plugin for our target platforms
build:
name: Building for ${{ matrix.platform }} (${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: true
matrix:
include:
# faster testing by disabling the others...
- os: macos-latest
platform: macos
- os: windows-latest
platform: windows

steps:
- name: Setup actions
uses: actions/checkout@v2
with:
submodules: 'recursive'

- name: Add msbuild to PATH (Windows)
uses: microsoft/setup-msbuild@v1.1
with:
msbuild-architecture: x64
if: matrix.platform == 'windows'

- name: Get SDK (MacOS)
run: |
curl -O "ftp://ftp.omnis.net/OmnisStudio/Studio102_31315/SDK/osx64/OSX-SDK-10.2-31315.dmg"
hdiutil attach OSX-SDK-10.2-31315.dmg
cp -a /volumes/OSX-SDK-10.2-31315/OSX-SDK-10.2-31315/. thirdparty/omnis.sdk/mac/
hdiutil detach /volumes/OSX-SDK-10.2-31315
if: matrix.platform == 'macos'

- name: Get SDK (Windows)
run: |
curl -O "ftp://ftp.omnis.net/OmnisStudio/Studio102_31315/SDK/windows/Windows-SDK-10.2-31315-x86-x64.zip"
tar -xf Windows-SDK-10.2-31315-x86-x64.zip
xcopy /E /I Windows-SDK-10.2-31315-x86-x64\* thirdparty\omnis.sdk\win\
if: matrix.platform == 'windows'

- name: Build (MacOS)
run: |
xcodebuild -project oExample.xcodeproj build
if: matrix.platform == 'macos'

- name: Build (Windows)
run: |
MSBuild example.vcxproj /property:Platform=x64 /property:Configuration="UNICODE Release"
if: matrix.platform == 'windows'

- name: Upload build files (artifacts) (MacOS)
uses: actions/upload-artifact@v2
with:
name: xcomp-macos
path: |
_OSXUnicode
if: matrix.platform == 'macos'

- name: Upload build files (artifacts) (Windows)
uses: actions/upload-artifact@v2
with:
name: xcomp-windows
path: |
URel64/example.dll
if: matrix.platform == 'windows'

# This job collects the build output and assembles the final asset (artifact)
asset:
name: Assembling the asset (artifact)
runs-on: ubuntu-20.04
needs: build
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- name: Download all workflow run artifacts
uses: actions/download-artifact@v2
- name: Copy files to destination
run: |
mkdir oExample
mkdir oExample/macos
mkdir oExample/windows
cp -a xcomp-macos/. oExample/macos/
cp xcomp-windows/example.dll oExample/windows/
- name: Get tag name
run: |
echo "GITHUB_SHA_SHORT=$(echo ${GITHUB_REF##*/})" >> $GITHUB_ENV
if: startsWith(github.ref, 'refs/tags')
- name: Zip asset
run: |
zip -qq -r oExample.zip oExample/.
- name: Create and upload asset
uses: ncipollo/release-action@v1
with:
allowUpdates: true
artifacts: "oExample.zip"
token: ${{ secrets.GITHUB_TOKEN }}

2 changes: 2 additions & 0 deletions .github/workflows/scripts/clang_format.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ while IFS= read -rd '' f; do
continue
elif [[ "$f" == "examples"* ]]; then
continue
elif [[ "$f" == "thirdparty"* ]]; then
continue
fi
for extension in ${CLANG_FORMAT_FILE_EXTS[@]}; do
if [[ "$f" == *"$extension" ]]; then
Expand Down
22 changes: 14 additions & 8 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
*.ncb
/*.suo
/*.sln
/*.user
/*.sdf
# mac
_OSXUnicodeDbg
_OSXUnicode
UnicodeCore.build
oExample.xcodeproj/*
!oExample.xcodeproj/project.pbxproj
.DS_Store

#windows
Release
UDeb
URel
URel64
UDeb64
UnicodeCore.build
build
.vs
.DS_Store
*.ncb
/*.suo
/*.sln
/*.user
/*.sdf
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "thirdparty/omnis.xcomp.framework"]
path = thirdparty/omnis.xcomp.framework
url = https://github.com/BastiaanOlij/omnis.xcomp.framework
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog
Notable changes to versions in this repository

## ????
- Moving build system to Studio 10.2
- Removed all build systems

## 2019-02-04
- Making this work on Studio 10.0
3 changes: 3 additions & 0 deletions English.lproj/Bitmap.strings
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"COMP_RES_1" = "OEXAMPLE.PNG";
}
11 changes: 11 additions & 0 deletions English.lproj/Localizable.strings
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"COMP_RES_1000" = "Example Library";
"COMP_RES_2000" = "Example Object";
"COMP_RES_2100" = "Example NVObject";
"COMP_RES_7000" = "test:Test value";
"COMP_RES_8000" = "$testMethod:$testMethod() Just a test method that returns a test string.";
"COMP_RES_8100" = "$nvTestMethod:$nvTestMethod() Just a test method that returns a test string.";
"COMP_RES_8101" = "$testCallback:$testCallback() Just a test mehtod that calls back into Omnis.";
"COMP_RES_8102" = "$evCallback:$evCallback() this method gets called by $testCallback.";
"COMP_RES_31000" = "FrameworkWndProc";
}
Binary file added English.lproj/OEXAMPLE.PNG
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
7 changes: 1 addition & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,7 @@ omnis.xcomp.example

Example xcomp made with omnis.xcomp.framework

Directories are setup relative and assume the framework is installed within the Omnis SDK folders:
- Omnis SDK
- complib
- omnis.xcomp.framework
- omnis.xcomp.example
- ...
Our framework is included as a submodule so make sure to clone recursively or run `git submodule update --init --recursive`

Compiling under Mac OS X
========================
Expand Down
66 changes: 33 additions & 33 deletions example_OS10.0.vcxproj → example.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -20,27 +20,27 @@
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{D377AD87-8C8E-47F3-987D-428CF82E73FF}</ProjectGuid>
<WindowsTargetPlatformVersion>10.0.15063.0</WindowsTargetPlatformVersion>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='UNICODE Debug|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v141</PlatformToolset>
<PlatformToolset>v142</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='UNICODE Debug|x64'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v141</PlatformToolset>
<PlatformToolset>v142</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='UNICODE Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v141</PlatformToolset>
<PlatformToolset>v142</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='UNICODE Release|x64'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v141</PlatformToolset>
<PlatformToolset>v142</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
Expand Down Expand Up @@ -98,7 +98,7 @@
<ClCompile>
<Optimization>MinSpace</Optimization>
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
<AdditionalIncludeDirectories>..\complib;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>thirdparty\omnis.sdk\win\complib;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>NDEBUG;WIN32;_WINDOWS;iswin32;isXCOMPLIB;NO_STRICT;isunicode;UNICODE;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_CRT_NONSTDC_NO_DEPRECATE;_UNICODE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<StringPooling>true</StringPooling>
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
Expand All @@ -120,7 +120,7 @@
<AdditionalDependencies>odbc32.lib;odbccp32.lib;omnisu.lib;%(AdditionalDependencies)</AdditionalDependencies>
<OutputFile>.\URel/generic.dll</OutputFile>
<SuppressStartupBanner>true</SuppressStartupBanner>
<AdditionalLibraryDirectories>..\ulibs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<AdditionalLibraryDirectories>thirdparty\omnis.sdk\win\ulibs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<IgnoreSpecificDefaultLibraries>libc.lib;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
<ModuleDefinitionFile>.\Generic.def</ModuleDefinitionFile>
<ProgramDatabaseFile>.\URel/GENERIC.pdb</ProgramDatabaseFile>
Expand All @@ -147,7 +147,7 @@
<ClCompile>
<Optimization>MinSpace</Optimization>
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
<AdditionalIncludeDirectories>..\complib;..\omnis.xcomp.framework;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>thirdparty\omnis.sdk\win\complib;thirdparty\omnis.xcomp.framework;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>NDEBUG;is64bit;_WINDOWS;iswin32;isXCOMPLIB;NO_STRICT;isunicode;UNICODE;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_CRT_NONSTDC_NO_DEPRECATE;_UNICODE;OMNISSDK=100;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<StringPooling>true</StringPooling>
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
Expand All @@ -169,7 +169,7 @@
<AdditionalDependencies>odbc32.lib;odbccp32.lib;omnisu64.lib;%(AdditionalDependencies)</AdditionalDependencies>
<OutputFile>.\URel64/example.dll</OutputFile>
<SuppressStartupBanner>true</SuppressStartupBanner>
<AdditionalLibraryDirectories>..\ulibs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<AdditionalLibraryDirectories>thirdparty\omnis.sdk\win\ulibs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<IgnoreSpecificDefaultLibraries>libc.lib;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
<ModuleDefinitionFile>.\example.def</ModuleDefinitionFile>
<ProgramDatabaseFile>.\URel64/example.pdb</ProgramDatabaseFile>
Expand All @@ -195,7 +195,7 @@
</Midl>
<ClCompile>
<Optimization>Disabled</Optimization>
<AdditionalIncludeDirectories>..\complib;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>thirdparty\omnis.sdk\win\complib;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>_DEBUG;WIN32;_WINDOWS;iswin32;isXCOMPLIB;NO_STRICT;isunicode;_UNICODE;UNICODE;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_CRT_NONSTDC_NO_DEPRECATE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>true</MinimalRebuild>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
Expand All @@ -217,7 +217,7 @@
<AdditionalDependencies>odbc32.lib;odbccp32.lib;omnisu.lib;%(AdditionalDependencies)</AdditionalDependencies>
<OutputFile>.\UDeb/generic.dll</OutputFile>
<SuppressStartupBanner>true</SuppressStartupBanner>
<AdditionalLibraryDirectories>..\ulibs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<AdditionalLibraryDirectories>thirdparty\omnis.sdk\win\ulibs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<IgnoreSpecificDefaultLibraries>libc.lib;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
<ModuleDefinitionFile>.\Generic.def</ModuleDefinitionFile>
<GenerateDebugInformation>true</GenerateDebugInformation>
Expand All @@ -243,7 +243,7 @@
</Midl>
<ClCompile>
<Optimization>Disabled</Optimization>
<AdditionalIncludeDirectories>..\complib;..\omnis.xcomp.framework;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<AdditionalIncludeDirectories>thirdparty\omnis.sdk\win\complib;thirdparty\omnis.xcomp.framework;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>_DEBUG;is64bit;_WINDOWS;iswin32;isXCOMPLIB;NO_STRICT;isunicode;_UNICODE;UNICODE;_CRT_SECURE_NO_DEPRECATE;_CRT_NON_CONFORMING_SWPRINTFS;_CRT_NONSTDC_NO_DEPRECATE;OMNISSDK=100;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
<StructMemberAlignment>Default</StructMemberAlignment>
Expand All @@ -264,7 +264,7 @@
<AdditionalDependencies>odbc32.lib;odbccp32.lib;omnisu64.lib;%(AdditionalDependencies)</AdditionalDependencies>
<OutputFile>.\UDeb64/example.dll</OutputFile>
<SuppressStartupBanner>true</SuppressStartupBanner>
<AdditionalLibraryDirectories>..\ulibs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<AdditionalLibraryDirectories>thirdparty\omnis.sdk\win\ulibs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<IgnoreSpecificDefaultLibraries>libc.lib;%(IgnoreSpecificDefaultLibraries)</IgnoreSpecificDefaultLibraries>
<ModuleDefinitionFile>.\example.def</ModuleDefinitionFile>
<GenerateDebugInformation>true</GenerateDebugInformation>
Expand All @@ -280,15 +280,15 @@
</Bscmake>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="..\omnis.xcomp.framework\FrameworkWndProc.cpp" />
<ClCompile Include="..\omnis.xcomp.framework\oBaseComponent.cpp" />
<ClCompile Include="..\omnis.xcomp.framework\oBaseNVComponent.cpp" />
<ClCompile Include="..\omnis.xcomp.framework\oBaseVisComponent.cpp" />
<ClCompile Include="..\omnis.xcomp.framework\oDrawingCanvas.cpp" />
<ClCompile Include="..\omnis.xcomp.framework\oRGBAImage.cpp" />
<ClCompile Include="..\omnis.xcomp.framework\oUTF8.cpp" />
<ClCompile Include="..\omnis.xcomp.framework\oXCompLib.cpp" />
<ClCompile Include="..\omnis.xcomp.framework\qString.cpp" />
<ClCompile Include="thirdparty\omnis.xcomp.framework\FrameworkWndProc.cpp" />
<ClCompile Include="thirdparty\omnis.xcomp.framework\oBaseComponent.cpp" />
<ClCompile Include="thirdparty\omnis.xcomp.framework\oBaseNVComponent.cpp" />
<ClCompile Include="thirdparty\omnis.xcomp.framework\oBaseVisComponent.cpp" />
<ClCompile Include="thirdparty\omnis.xcomp.framework\oDrawingCanvas.cpp" />
<ClCompile Include="thirdparty\omnis.xcomp.framework\oRGBAImage.cpp" />
<ClCompile Include="thirdparty\omnis.xcomp.framework\oUTF8.cpp" />
<ClCompile Include="thirdparty\omnis.xcomp.framework\oXCompLib.cpp" />
<ClCompile Include="thirdparty\omnis.xcomp.framework\qString.cpp" />
<ClCompile Include="Src\example.cpp" />
<ClCompile Include="Src\oExample.cpp" />
<ClCompile Include="Src\oNVExample.cpp" />
Expand All @@ -303,17 +303,17 @@
<Image Include="English.lproj\oExample.bmp" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\omnis.xcomp.framework\oBaseComponent.h" />
<ClInclude Include="..\omnis.xcomp.framework\oBaseNVComponent.h" />
<ClInclude Include="..\omnis.xcomp.framework\oBaseVisComponent.h" />
<ClInclude Include="..\omnis.xcomp.framework\oDrawingCanvas.h" />
<ClInclude Include="..\omnis.xcomp.framework\omnis.xcomp.framework.h" />
<ClInclude Include="..\omnis.xcomp.framework\oRGBAImage.h" />
<ClInclude Include="..\omnis.xcomp.framework\oUTF8.h" />
<ClInclude Include="..\omnis.xcomp.framework\oXCompLib.h" />
<ClInclude Include="..\omnis.xcomp.framework\qArray.h" />
<ClInclude Include="..\omnis.xcomp.framework\qString.h" />
<ClInclude Include="..\omnis.xcomp.framework\xCompStandardIncludes.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\oBaseComponent.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\oBaseNVComponent.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\oBaseVisComponent.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\oDrawingCanvas.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\omnis.xcomp.framework.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\oRGBAImage.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\oUTF8.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\oXCompLib.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\qArray.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\qString.h" />
<ClInclude Include="thirdparty\omnis.xcomp.framework\xCompStandardIncludes.h" />
<ClInclude Include="Src\example.h" />
<ClInclude Include="Src\oExample.h" />
<ClInclude Include="Src\oNVExample.h" />
Expand Down
Loading

0 comments on commit afe63f4

Please sign in to comment.