8000 Build script fixes. · pythonnet/pythonnet@3e2bfe1 · GitHub
[go: up one dir, main page]

Skip to content

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

< 10000 div class="position-relative HeaderMenu-link-wrap d-lg-inline-block">
Appearance settings

Commit 3e2bfe1

Browse files
author
dse
committed
Build script fixes.
1 parent 6d746eb commit 3e2bfe1

File tree

4 files changed

+144
-132
lines changed

4 files changed

+144
-132
lines changed

.travis.yml

Lines changed: 110 additions & 110 deletions
Original file line numberDiff line numberDiff line change
@@ -4,82 +4,82 @@ language: python
44

55
matrix:
66
include:
7-
- python: 2.7
8-
env:
9-
- BUILD_OPTS=
10-
- NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
11-
- python: 3.3
12-
env:
13-
- BUILD_OPTS=
14-
- NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
15-
- python: 3.4
16-
env:
17-
- BUILD_OPTS=
18-
- NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
19-
- python: 3.5
20-
env:
21-
- BUILD_OPTS=
22-
- NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
23-
- python: 3.6
24-
env:
25-
- BUILD_OPTS=
26-
- NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
27-
- python: "3.7-dev"
28-
env:
29-
- BUILD_OPTS=
30-
- NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
7+
# - python: 2.7
8+
# env:
9+
# - BUILD_OPTS=
10+
# - NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
11+
# - python: 3.3
12+
# env:
13+
# - BUILD_OPTS=
14+
# - NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
15+
# - python: 3.4
16+
# env:
17+
# - BUILD_OPTS=
18+
# - NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
19+
# - python: 3.5
20+
# env:
21+
# - BUILD_OPTS=
22+
# - NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
23+
# - python: 3.6
24+
# env:
25+
# - BUILD_OPTS=
26+
# - NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
27+
# - python: "3.7-dev"
28+
# env:
29+
# - BUILD_OPTS=
30+
# - NUNIT_PATH=./packages/NUnit.*/tools/nunit3-console.exe
3131

32-
- python: 2.7
33-
env:
34-
- BUILD_OPTS=--xplat
35-
- NUNIT_PATH=~/.nuget/packages/nunit.consolerunner/3.*/tools/nunit3-console.exe
36-
addons:
37-
apt:
38-
sources:
39-
- sourceline: deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main
40-
key_url: https://packages.microsoft.com/keys/microsoft.asc
41-
- sourceline: deb http://download.mono-project.com/repo/ubuntu trusty main
42-
key_url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xA6A19B38D3D831EF
43-
packages:
44-
- mono-devel
45-
- ca-certificates-mono
46-
- dotnet-hostfxr-2.0.0
47-
- dotnet-runtime-2.0.0
48-
- dotnet-sdk-2.0.0
49-
- python: 3.3
50-
env:
51-
- BUILD_OPTS=--xplat
52-
- NUNIT_PATH=~/.nuget/packages/nunit.consolerunner/3.*/tools/nunit3-console.exe
53-
addons:
54-
apt:
55-
sources:
56-
- sourceline: deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main
57-
key_url: https://packages.microsoft.com/keys/microsoft.asc
58-
- sourceline: deb http://download.mono-project.com/repo/ubuntu trusty main
59-
key_url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xA6A19B38D3D831EF
60-
packages:
61-
- mono-devel
62-
- ca-certificates-mono
63-
- dotnet-hostfxr-2.0.0
64-
- dotnet-runtime-2.0.0
65-
- dotnet-sdk-2.0.0
66-
- python: 3.4
67-
env:
68-
- BUILD_OPTS=--xplat
69-
- NUNIT_PATH=~/.nuget/packages/nunit.consolerunner/3.*/tools/nunit3-console.exe
70-
addons:
71-
apt:
72-
sources:
73-
- sourceline: deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main
74-
key_url: https://packages.microsoft.com/keys/microsoft.asc
75-
- sourceline: deb http://download.mono-project.com/repo/ubuntu trusty main
76-
key_url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xA6A19B38D3D831EF
77-
packages:
78-
- mono-devel
79-
- ca-certificates-mono
80-
- dotnet-hostfxr-2.0.0
81-
- dotnet-runtime-2.0.0
82-
- dotnet-sdk-2.0.0
32+
# - python: 2.7
33+
# env:
34+
# - BUILD_OPTS=--xplat
35+
# - NUNIT_PATH=~/.nuget/packages/nunit.consolerunner/3.*/tools/nunit3-console.exe
36+
# addons:
37+
# apt:
38+
# sources:
39+
# - sourceline: deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main
40+
# key_url: https://packages.microsoft.com/keys/microsoft.asc
41+
# - sourceline: deb http://download.mono-project.com/repo/ubuntu trusty main
42+
# key_url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xA6A19B38D3D831EF
43+
# packages:
44+
# - mono-devel
45+
# - ca-certificates-mono
46+
# - dotnet-hostfxr-2.0.0
47+
# - dotnet-runtime-2.0.0
48+
# - dotnet-sdk-2.0.0
49+
# - python: 3.3
50+
# env:
51+
# - BUILD_OPTS=--xplat
52+
# - NUNIT_PATH=~/.nuget/packages/nunit.consolerunner/3.*/tools/nunit3-console.exe
53+
# addons:
54+
# apt:
55+
# sources:
56+
# - sourceline: deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main
57+
# key_url: https://packages.microsoft.com/keys/microsoft.asc
58+
# - sourceline: deb http://download.mono-project.com/repo/ubuntu trusty main
59+
# key_url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xA6A19B38D3D831EF
60+
# packages:
61+
# - mono-devel
62+
# - ca-certificates-mono
63+
# - dotnet-hostfxr-2.0.0
64+
# - dotnet-runtime-2.0.0
65+
# - dotnet-sdk-2.0.0
66+
# - python: 3.4
67+
# env:
68+
# - BUILD_OPTS=--xplat
69+
# - NUNIT_PATH=~/.nuget/packages/nunit.consolerunner/3.*/tools/nunit3-console.exe
70+
# addons:
71+
# apt:
72+
# sources:
73+
# - sourceline: deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main
74+
# key_url: https://packages.microsoft.com/keys/microsoft.asc
75+
# - sourceline: deb http://download.mono-project.com/repo/ubuntu trusty main
76+
# key_url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xA6A19B38D3D831EF
77+
# packages:
78+
# - mono-devel
79+
# - ca-certificates-mono
80+
# - dotnet-hostfxr-2.0.0
81+
# - dotnet-runtime-2.0.0
82+
# - dotnet-sdk-2.0.0
8383
- python: 3.5
8484
env:
8585
- BUILD_OPTS=--xplat
@@ -97,40 +97,40 @@ matrix:
9797
- dotnet-hostfxr-2.0.0
9898
- dotnet-runtime-2.0.0
9999
- dotnet-sdk-2.0.0
100-
- python: 3.6
101-
env:
102-
- BUILD_OPTS=--xplat
103-
- NUNIT_PATH=~/.nuget/packages/nunit.consolerunner/3.*/tools/nunit3-console.exe
104-
addons:
105-
apt:
106-
sources:
107-
- sourceline: deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main
108-
key_url: https://packages.microsoft.com/keys/microsoft.asc
109-
- sourceline: deb http://download.mono-project.com/repo/ubuntu trusty main
110-
key_url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xA6A19B38D3D831EF
111-
packages:
112-
- mono-devel
113-
- ca-certificates-mono
114-
- dotnet-hostfxr-2.0.0
115-
- dotnet-runtime-2.0.0
116-
- dotnet-sdk-2.0.0
117-
- python: "3.7-dev"
118-
env:
119-
- BUILD_OPTS=--xplat
120-
- NUNIT_PATH=~/.nuget/packages/nunit.consolerunner/3.*/tools/nunit3-console.exe
121-
addons:
122-
apt:
123-
sources:
124-
- sourceline: deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main
125-
key_url: https://packages.microsoft.com/keys/microsoft.asc
126-
- sourceline: deb http://download.mono-project.com/repo/ubuntu trusty main
127-
key_url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xA6A19B38D3D831EF
128-
packages:
129-
- mono-devel
130-
- ca-certificates-mono
131-
- dotnet-hostfxr-2.0.0
132-
- dotnet-runtime-2.0.0
133-
- dotnet-sdk-2.0.0
100+
# - python: 3.6
101+
# env:
102+
# - BUILD_OPTS=--xplat
103+
# - NUNIT_PATH=~/.nuget/packages/nunit.consolerunner/3.*/tools/nunit3-console.exe
104+
# addons:
105+
# apt:
106+
# sources:
107+
# - sourceline: deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main
108+
# key_url: https://packages.microsoft.com/keys/microsoft.asc
109+
# - sourceline: deb http://download.mono-project.com/repo/ubuntu trusty main
110+
# key_url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xA6A19B38D3D831EF
111+
# packages:
112+
# - mono-devel
113+
# - ca-certificates-mono
114+
# - dotnet-hostfxr-2.0.0
115+
# - dotnet-runtime-2.0.0
116+
# - dotnet-sdk-2.0.0
117+
# - python: "3.7-dev"
118+
# env:
119+
# - BUILD_OPTS=--xplat
120+
# - NUNIT_PATH=~/.nuget/packages/nunit.consolerunner/3.*/tools/nunit3-console.exe
121+
# addons:
122+
# apt:
123+
# sources:
124+
# - sourceline: deb [arch=amd64] https://packages.microsoft.com/repos/microsoft-ubuntu-trusty-prod trusty main
125+
# key_url: https://packages.microsoft.com/keys/microsoft.asc
126+
# - sourceline: deb http://download.mono-project.com/repo/ubuntu trusty main
127+
# key_url: http://keyserver.ubuntu.com/pks/lookup?op=get&search=0xA6A19B38D3D831EF
128+
# packages:
129+
# - mono-devel
130+
# - ca-certificates-mono
131+
# - dotnet-hostfxr-2.0.0
132+
# - dotnet-runtime-2.0.0
133+
# - dotnet-sdk-2.0.0
134134
allow_failures:
135135
- python: "3.7-dev"
136136
env:
@@ -169,7 +169,7 @@ install:
169169
script:
170170
- python -m pytest
171171
- mono $NUNIT_PATH src/embed_tests/bin/Python.EmbeddingTest.dll
172-
- dotnet src/embed_tests/bin/netcoreapp2.0_publish/Python.EmbeddingTest.dll
172+
- if [[ $BUILD_OPTS == --xplat ]]; then dotnet src/embed_tests/bin/netcoreapp2.0_publish/Python.EmbeddingTest.dll; fi
173173

174174
after_script:
175175
# Uncomment if need to geninterop, ie. py37 final

appveyor.yml

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -15,21 +15,21 @@ environment:
1515
CODECOV_ENV: PYTHON_VERSION, PLATFORM
1616

1717
matrix:
18-
- PYTHON_VERSION: 2.7
19-
- PYTHON_VERSION: 3.3
20-
- PYTHON_VERSION: 3.4
18+
# - PYTHON_VERSION: 2.7
19+
# - PYTHON_VERSION: 3.3
20+
# - PYTHON_VERSION: 3.4
21+
# - PYTHON_VERSION: 3.5
22+
# - PYTHON_VERSION: 3.6
23+
# - PYTHON_VERSION: 2.7
24+
# BUILD_OPTS: --xplat
25+
# - PYTHON_VERSION: 3.3
26+
# BUILD_OPTS: --xplat
27+
# - PYTHON_VERSION: 3.4
28+
# BUILD_OPTS: --xplat
2129
- PYTHON_VERSION: 3.5
22-
- PYTHON_VERSION: 3.6
23-
- PYTHON_VERSION: 2.7
24-
BUILD_OPTS: --xplat
25-
- PYTHON_VERSION: 3.3
26-
BUILD_OPTS: --xplat
27-
- PYTHON_VERSION: 3.4
28-
BUILD_OPTS: --xplat
29-
- PYTHON_VERSION: 3.5
30-
BUILD_OPTS: --xplat
31-
- PYTHON_VERSION: 3.6
3230
BUILD_OPTS: --xplat
31+
# - PYTHON_VERSION: 3.6
32+
# BUILD_OPTS: --xplat
3333

3434
init:
3535
# Update Environment Variables based on matrix/platform
@@ -43,7 +43,8 @@ init:
4343
install:
4444
- pip install --upgrade -r requirements.txt --quiet
4545
- choco install vswhere -y
46-
46+
- cmd: curl -O https://download.microsoft.com/download/5/6/B/56BFEF92-9045-4414-970C-AB31E0FC07EC/dotnet-runtime-2.0.0-win-x86.exe
47+
- cmd: dotnet-runtime-2.0.0-win-x86.exe /install /quiet /norestart /log install.log
4748
# Install OpenCover. Can't put on `packages.config`, not Mono compatible
4849
- .\tools\nuget\nuget.exe install OpenCover -OutputDirectory packages -Verbosity quiet
4950

ci/appveyor_run_tests.ps1

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -44,12 +44,21 @@ if ($CS_STATUS -ne 0) {
4444
Write-Host "Embedded tests failed" -ForegroundColor "Red"
4545
}
4646

47-
# Run Embedded tests for netcoreapp2.0 (OpenCover currently does not supports dotnet core)
48-
Write-Host ("Starting embedded tests for netcoreapp2.0") -ForegroundColor "Green"
49-
&dotnet .\src\embed_tests\bin\netcoreapp2.0_publish\Python.EmbeddingTest.dll
50-
$CS_STATUS = $LastExitCode
51-
if ($CS_STATUS -ne 0) {
52-
Write-Host "Embedded tests for netcoreapp2.0 failed" -ForegroundColor "Red"
47+
if ($env:BUILD_OPTS -eq "--xplat"){
48+
if ($FALSE -and $env:PLATFORM -eq "x86") {
49+
$DOTNET_CMD = "c:\Program Files (x86)\dotnet\dotnet"
50+
}
51+
else{
52+
$DOTNET_CMD = "dotnet"
53+
}
54+
55+
# Run Embedded tests for netcoreapp2.0 (OpenCover currently does not supports dotnet core)
56+
Write-Host ("Starting embedded tests for netcoreapp2.0") -ForegroundColor "Green"
57+
&$DOTNET_CMD .\src\embed_tests\bin\netcoreapp2.0_publish\Python.EmbeddingTest.dll
58+
$CS_STATUS = $LastExitCode
59+
if ($CS_STATUS -ne 0) {
60+
Write-Host "Embedded tests for netcoreapp2.0 failed" -ForegroundColor "Red"
61+
}
5362
}
5463

5564
# Set exit code to fail if either Python or Embedded tests failed

setup.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -257,9 +257,11 @@ def build_extension(self, ext):
257257

258258
subprocess.check_call(" ".join(cmd + ["/t:Clean"]), shell=use_shell)
259259
subprocess.check_call(" ".join(cmd + ["/t:Build"]), shell=use_shell)
260-
if DEVTOOLS == "dotnet" or DEVTOOLS == "MsDev15":
260+
if DEVTOOLS == "MsDev15":
261261
subprocess.check_call(" ".join(cmd + ["/t:Console_15:publish;Python_EmbeddingTest_15:publish", "/p:TargetFramework=netcoreapp2.0"]), shell=use_shell)
262-
262+
elif DEVTOOLS == "dotnet"
263+
subprocess.check_call(" ".join(cmd + ["/t:publish", "/p:TargetFramework=netcoreapp2.0"]), shell=use_shell)
264+
263265
if DEVTOOLS == "Mono" or DEVTOOLS == "dotnet":
264266
self._build_monoclr()
265267

0 commit comments

Comments
 (0)
0