Skip to content

Commit 516b46f

Browse files
committed
- github action as starting point
- update NuGet.CommandLine -> NuGet.CommandLine.6.9.1 - add initial appveyor.yml CI config - prepare for boost 1.86.0 - disabled upload of nuget to avoid upload quota exceeded with appveyor - added dummy ApiKey.cs - avoid nuget warnings about: WARNING: NU5125: The 'licenseUrl' element will be deprecated. Consider using the 'license' element instead. WARNING: NU5128: Some target frameworks declared in the dependencies group of the nuspec and the lib/ref folder do not have exact matches in the other location. Consult the list of actions below: - Add a dependency group for native0.0 to the nuspec
1 parent df9cbbc commit 516b46f

File tree

9 files changed

+195
-9
lines changed

9 files changed

+195
-9
lines changed

.github/dependabot.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# To get started with Dependabot version updates, you'll need to specify which
2+
# package ecosystems to update and where the package manifests are located.
3+
# Please see the documentation for all configuration options:
4+
# https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
5+
6+
version: 2
7+
updates:
8+
- package-ecosystem: "nuget" # See documentation for possible values
9+
directory: "/" # Location of package manifests
10+
schedule:
11+
interval: "monthly"
12+
13+
# Maintain dependencies for GitHub Actions
14+
- package-ecosystem: "github-actions"
15+
directory: "/"
16+
schedule:
17+
interval: "monthly"

.github/workflows/CI_build.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: CI_build
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
build:
7+
8+
runs-on: windows-latest
9+
strategy:
10+
matrix:
11+
build_configuration: [Release]
12+
build_platform: [Any CPU]
13+
build_boost_version: [1_86_0]
14+
build_boost_version_dot: [1.86.0]
15+
build_msvc_version_dot: [14.3, 14.2, 14.1]
16+
steps:
17+
- name: Checkout repo
18+
uses: actions/checkout@v4
19+
20+
- name: Setup Nuget.exe
21+
uses: nuget/setup-nuget@v2
22+
23+
- name: restore input nuget packages
24+
working-directory: builder\
25+
run: |
26+
nuget restore builder\packages.config -PackagesDirectory packages
27+
nuget restore builderTest\packages.config -PackagesDirectory packages
28+
29+
- name: Setup to add MSBuild.exe to path
30+
uses: microsoft/setup-msbuild@v2
31+
32+
- name: MSBuild of builder
33+
working-directory: builder\
34+
run: |
35+
msbuild builder.sln /m /verbosity:minimal /t:restore /p:configuration="${{ matrix.build_configuration }}" /p:platform="${{ matrix.build_platform }}"
36+
msbuild builder.sln /m /p:configuration="${{ matrix.build_configuration }}" /p:platform="${{ matrix.build_platform }}"
37+
38+
- name: boost binary download created by https://github.com/teeks99/boost-release-windows
39+
working-directory: .
40+
run: |
41+
Set-Location -Path 'D:\a'
42+
New-Item -ItemType directory -Path D:\a\boostorg
43+
Set-Location -Path 'D:\a\boostorg'
44+
(New-Object System.Net.WebClient).DownloadFile("https://boostorg.jfrog.io/artifactory/main/release/${{ matrix.build_boost_version_dot }}/binaries/boost_${{ matrix.build_boost_version }}-msvc-${{ matrix.build_msvc_version_dot }}-64.exe", "D:\a\boostorg\boost_${{ matrix.build_boost_version }}-msvc-${{ matrix.build_msvc_version_dot }}-64.exe")
45+
(New-Object System.Net.WebClient).DownloadFile("https://boostorg.jfrog.io/artifactory/main/release/${{ matrix.build_boost_version_dot }}/binaries/boost_${{ matrix.build_boost_version }}-msvc-${{ matrix.build_msvc_version_dot }}-32.exe", "D:\a\boostorg\boost_${{ matrix.build_boost_version }}-msvc-${{ matrix.build_msvc_version_dot }}-32.exe")
46+
.\boost_${{ matrix.build_boost_version }}-msvc-${{ matrix.build_msvc_version_dot }}-64.exe /SILENT /DIR=D:\a\boostorg\boost | Out-Null
47+
.\boost_${{ matrix.build_boost_version }}-msvc-${{ matrix.build_msvc_version_dot }}-32.exe /SILENT /DIR=D:\a\boostorg\boost | Out-Null
48+
49+
- name: run builder
50+
working-directory: builder\builder\bin\Release\
51+
run: .\builder.exe

appveyor.yml

Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
version: 1.85.{build}
2+
3+
4+
environment:
5+
matrix:
6+
7+
- PlatformToolset: v143
8+
APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2022
9+
BUILD_BOOST_VERSION: 1_85_0
10+
BUILD_BOOST_VERSION_DOT: 1.85.0
11+
BUILD_MSVC_VERSION_DOT: 14.3
12+
13+
configuration:
14+
- Release
15+
#- Debug
16+
17+
platform:
18+
- Any CPU
19+
20+
install:
21+
- if "%platform%"=="Any CPU" set archi=amd64
22+
- if "%platform%"=="Any CPU" set platform_input=Any CPU
23+
24+
25+
- if "%PlatformToolset%"=="v140" call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" %archi%
26+
- if "%PlatformToolset%"=="v141" call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" %archi%
27+
- if "%PlatformToolset%"=="v142" call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Auxiliary\Build\vcvarsall.bat" %archi%
28+
- if "%PlatformToolset%"=="v143" call "C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Auxiliary\Build\vcvarsall.bat" %archi%
29+
30+
- cd "%APPVEYOR_BUILD_FOLDER%"\..\..
31+
- mkdir boostorg
32+
- cd boostorg
33+
# build from source, but fails due to runtime limitation as each build takes ~ 40min
34+
#- appveyor DownloadFile https://boostorg.jfrog.io/artifactory/main/release/%BUILD_BOOST_VERSION_DOT%/source/boost_%BUILD_BOOST_VERSION%.7z
35+
#- boost.bat
36+
37+
# Free disk space for boost zip package
38+
- rmdir /q /s C:\Qt
39+
- rmdir /q /s C:\Python26
40+
- rmdir /q /s C:\Python26-x64
41+
- rmdir /q /s C:\Python27
42+
- rmdir /q /s C:\Python27-x64
43+
- rmdir /q /s C:\Python33
44+
- rmdir /q /s C:\Python33-x64
45+
- rmdir /q /s C:\Python34
46+
- rmdir /q /s C:\Python34-x64
47+
- rmdir /q /s C:\Python35
48+
- rmdir /q /s C:\Python35-x64
49+
- rmdir /q /s C:\Python36
50+
- rmdir /q /s C:\Python36-x64
51+
- rmdir /q /s C:\Python37
52+
- rmdir /q /s C:\Python37-x64
53+
- rmdir /q /s C:\Python38
54+
- rmdir /q /s C:\Python38-x64
55+
- rmdir /q /s C:\Python39
56+
- rmdir /q /s C:\Python39-x64
57+
- rmdir /q /s C:\Python310
58+
- rmdir /q /s C:\Python310-x64
59+
- rmdir /q /s C:\Python311
60+
- rmdir /q /s C:\Python311-x64
61+
- rmdir /q /s C:\Python312
62+
- rmdir /q /s C:\Python312-x64
63+
64+
# complete zip, but fails due to storage limitations on appveyor (artifactory download is much faster than sourceforge)
65+
- appveyor DownloadFile https://boostorg.jfrog.io/artifactory/main/release/%BUILD_BOOST_VERSION_DOT%/binaries/boost_%BUILD_BOOST_VERSION%-bin-msvc-all-32-64.7z
66+
#- appveyor DownloadFile https://sourceforge.net/projects/boost/files/boost-binaries/%BUILD_BOOST_VERSION_DOT%/boost_%BUILD_BOOST_VERSION%-bin-msvc-all-32-64.7z
67+
- 7z x -y boost_%BUILD_BOOST_VERSION%-bin-msvc-all-32-64.7z > nul
68+
- del /q boost_%BUILD_BOOST_VERSION%-bin-msvc-all-32-64.7z
69+
- rename boost_%BUILD_BOOST_VERSION% boost
70+
71+
72+
#- appveyor DownloadFile https://boostorg.jfrog.io/artifactory/main/release/%BUILD_BOOST_VERSION_DOT%/binaries/boost_%BUILD_BOOST_VERSION%-msvc-%BUILD_MSVC_VERSION_DOT%-32.exe
73+
#- appveyor DownloadFile https://boostorg.jfrog.io/artifactory/main/release/%BUILD_BOOST_VERSION_DOT%/binaries/boost_%BUILD_BOOST_VERSION%-msvc-%BUILD_MSVC_VERSION_DOT%-64.exe
74+
#- boost_%BUILD_BOOST_VERSION%-msvc-%BUILD_MSVC_VERSION_DOT%-64.exe /SILENT /DIR=C:\boostorg\boost
75+
#- boost_%BUILD_BOOST_VERSION%-msvc-%BUILD_MSVC_VERSION_DOT%-32.exe /SILENT /DIR=C:\boostorg\boost
76+
77+
- nuget restore "%APPVEYOR_BUILD_FOLDER%"\builder\builder\packages.config -PackagesDirectory "%APPVEYOR_BUILD_FOLDER%"\builder\packages
78+
- nuget restore "%APPVEYOR_BUILD_FOLDER%"\builder\builderTest\packages.config -PackagesDirectory "%APPVEYOR_BUILD_FOLDER%"\builder\packages
79+
80+
81+
build_script:
82+
- cd "%APPVEYOR_BUILD_FOLDER%"\builder
83+
- msbuild builder.sln /m /verbosity:minimal /t:restore /p:configuration="%configuration%" /p:platform="%platform_input%" /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
84+
- msbuild builder.sln /m /verbosity:minimal /p:configuration="%configuration%" /p:platform="%platform_input%" /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
85+
- cd "%APPVEYOR_BUILD_FOLDER%"
86+
87+
after_build:
88+
- cd "%APPVEYOR_BUILD_FOLDER%"\builder\builder\bin\Release\
89+
- call builder.exe
90+
91+
artifacts:
92+
#- path: installer\build\**\*.*
93+
# name: releases
94+
95+
deploy:
96+
provider: GitHub
97+
auth_token:
98+
secure: #!TODO!
99+
artifact: releases
100+
draft: false
101+
prerelease: false
102+
force_update: true
103+
on:
104+
appveyor_repo_tag: true
105+
PlatformToolset: v143
106+
configuration: Release

builder/builder/ApiKey.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
//nuget api key needs to be placed here

builder/builder/App.config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<configuration>
33
<startup>
4-
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8"/>
4+
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8.1"/>
55
</startup>
66
</configuration>

builder/builder/Nuspec.cs

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,20 +63,21 @@ private static void CreateNuspec(
6363
N("version", version.ToString()),
6464
N("authors", Config.Authors),
6565
N("owners", Config.Owners),
66-
N("licenseUrl", "https://github.com/sergey-shandar/getboost/blob/master/LICENSE"),
66+
N("license", Xml.A("type", "expression")).Append("BSL-1.0"),
6767
N("projectUrl", "https://github.com/sergey-shandar/getboost"),
6868
N("requireLicenseAcceptance", "false"),
6969
N("description", description),
7070
N("dependencies").Append(
71+
N("group", Xml.A("targetFramework", "native")).Append(
7172
dependencyList.Select(
72-
d =>
73+
d =>
7374
N(
7475
"dependency",
7576
Xml.A("id", d.Id),
7677
Xml.A("version", d.Version)
7778
)
7879
)
79-
),
80+
)),
8081
N("tags", string.Join(" ", tags))
8182
),
8283
N("files").Append(fileList.Select(f => f.N))
@@ -93,7 +94,7 @@ private static void CreateNuspec(
9394
var nupkgFile = id + "." + version + ".nupkg";
9495
Console.WriteLine("uploading: " + nupkgFile);
9596
{
96-
var p = Process.Start(
97+
/* var p = Process.Start(
9798
new ProcessStartInfo(
9899
@"..\..\..\packages\NuGet.CommandLine.6.9.1\tools\nuget.exe",
99100
$"push {nupkgFile} -Source https://api.nuget.org/v3/index.json -ApiKey {ApiKey.Value}")
@@ -104,14 +105,14 @@ private static void CreateNuspec(
104105
if (p.ExitCode != 0) {
105106
Environment.Exit(p.ExitCode);
106107
}
107-
}
108+
*/ }
108109
}
109110

110111
public static void Create(
111112
string nuspecId,
112113
string packageId,
113114
Version version,
114-
string description,
115+
string description,
115116
IEnumerable<Targets.ItemDefinitionGroup> itemDefinitionGroupList,
116117
IEnumerable<File> fileList,
117118
IEnumerable<CompilationUnit> compilationUnitList,

builder/builder/builder.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<AppDesignerFolder>Properties</AppDesignerFolder>
1010
<RootNamespace>builder</RootNamespace>
1111
<AssemblyName>builder</AssemblyName>
12-
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
12+
<TargetFrameworkVersion>v4.8.1</TargetFrameworkVersion>
1313
<FileAlignment>512</FileAlignment>
1414
<TargetFrameworkProfile />
1515
</PropertyGroup>

builder/builderTest/builderTest.csproj

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<AppDesignerFolder>Properties</AppDesignerFolder>
99
<RootNamespace>builderTest</RootNamespace>
1010
<AssemblyName>builderTest</AssemblyName>
11-
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
11+
<TargetFrameworkVersion>v4.8.1</TargetFrameworkVersion>
1212
<FileAlignment>512</FileAlignment>
1313
<ProjectTypeGuids>{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
1414
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
@@ -40,7 +40,16 @@
4040
<SpecificVersion>False</SpecificVersion>
4141
<HintPath>..\packages\Framework.G1.1.0.13.0\lib\portable-net45+sl50+win+wp80+MonoAndroid10+MonoTouch10\Framework.G1.dll</HintPath>
4242
</Reference>
43+
<Reference Include="Microsoft.Build.Utilities.v4.0" />
44+
<Reference Include="Microsoft.CSharp" />
4345
<Reference Include="System" />
46+
<Reference Include="System.ComponentModel.Composition" />
47+
<Reference Include="System.ComponentModel.Composition.Registration" />
48+
<Reference Include="System.ComponentModel.DataAnnotations" />
49+
<Reference Include="System.IO.Compression" />
50+
<Reference Include="System.Net.Http" />
51+
<Reference Include="System.Xml" />
52+
<Reference Include="System.Xml.Linq" />
4453
</ItemGroup>
4554
<Choose>
4655
<When Condition="('$(VisualStudioVersion)' == '10.0' or '$(VisualStudioVersion)' == '') and '$(TargetFrameworkVersion)' == 'v3.5'">
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
33
<package id="Framework.G1" version="1.0.13.0" targetFramework="net451" />
4+
<package id="NuGet.CommandLine" version="6.9.1" targetFramework="net48" developmentDependency="true" />
45
</packages>

0 commit comments

Comments
 (0)