-
-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Windows build for mpc #3
Changes from 1 commit
a2298f0
08ad73f
890a583
b9562b5
dd5e139
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
|
||
# This file was automatically generated by conda-smithy. To update a component of this | ||
# file, make changes to conda-forge.yaml and/or recipe/meta.yaml, and run | ||
# "conda-smithy regenerate". | ||
|
||
environment: | ||
|
||
CONDA_INSTALL_LOCN: "C:\\conda" | ||
|
||
# SDK v7.0 MSVC Express 2008's SetEnv.cmd script will fail if the | ||
# /E:ON and /V:ON options are not enabled in the batch script intepreter | ||
# See: http://stackoverflow.com/a/13751649/163740 | ||
CMD_IN_ENV: "cmd /E:ON /V:ON /C obvci_appveyor_python_build_env.cmd" | ||
|
||
# We set a default Python version for the miniconda that is to be installed. This can be | ||
# overridden in the matrix definition where appropriate. | ||
CONDA_PY: "27" | ||
BINSTAR_TOKEN: | ||
# The BINSTAR_TOKEN secure variable. This is defined canonically in conda-forge.yml. | ||
secure: MP4hZYylDyUWEsrt3u3cod2sbFeRwUziH02mvQOdbjsTO/l1yIxDkP/76rSIjcGC | ||
|
||
matrix: | ||
- TARGET_ARCH: x86 | ||
CONDA_PY: 35 | ||
- TARGET_ARCH: x64 | ||
CONDA_PY: 35 | ||
|
||
|
||
# We always use a 64-bit machine, but can build x86 distributions | ||
# with the TARGET_ARCH variable. | ||
platform: | ||
- x64 | ||
|
||
install: | ||
# If there is a newer build queued for the same PR, cancel this one. | ||
# The AppVeyor 'rollout builds' option is supposed to serve the same | ||
# purpose but it is problematic because it tends to cancel builds pushed | ||
# directly to master instead of just PR builds (or the converse). | ||
# credits: JuliaLang developers. | ||
- ps: if ($env:APPVEYOR_PULL_REQUEST_NUMBER -and $env:APPVEYOR_BUILD_NUMBER -ne ((Invoke-RestMethod ` | ||
https://ci.appveyor.com/api/projects/$env:APPVEYOR_ACCOUNT_NAME/$env:APPVEYOR_PROJECT_SLUG/history?recordsNumber=50).builds | ` | ||
Where-Object pullRequestId -eq $env:APPVEYOR_PULL_REQUEST_NUMBER)[0].buildNumber) { ` | ||
throw "There are newer queued builds for this pull request, failing early." } | ||
|
||
# Cywing's git breaks conda-build. (See https://github.com/conda-forge/conda-smithy-feedstock/pull/2.) | ||
- cmd: rmdir C:\cygwin /s /q | ||
- appveyor DownloadFile "https://raw.githubusercontent.com/pelson/Obvious-CI/master/bootstrap-obvious-ci-and-miniconda.py" | ||
- cmd: python bootstrap-obvious-ci-and-miniconda.py %CONDA_INSTALL_LOCN% %TARGET_ARCH% %CONDA_PY:~0,1% --without-obvci | ||
- cmd: set PATH=%CONDA_INSTALL_LOCN%;%CONDA_INSTALL_LOCN%\scripts;%PATH% | ||
- cmd: set PYTHONUNBUFFERED=1 | ||
|
||
- cmd: conda install -c http://conda.binstar.org/pelson/channel/development --yes --quiet obvious-ci | ||
- cmd: conda config --add channels http://conda.binstar.org/conda-forge | ||
- cmd: conda info | ||
- cmd: conda install -n root --quiet --yes conda-build anaconda-client jinja2 setuptools | ||
|
||
# Skip .NET project specific build phase. | ||
build: off | ||
|
||
test_script: | ||
- "%CMD_IN_ENV% conda build recipe --quiet" | ||
deploy_script: | ||
|
||
- 'python ci_support\upload_or_check_non_existence.py .\recipe conda-forge --channel=main' |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
if "%ARCH%"=="32" ( | ||
set PLATFORM=Win32 | ||
) else ( | ||
set PLATFORM=x64 | ||
) | ||
|
||
set mpc_root=%cd% | ||
cd .. | ||
|
||
for %%d in (mpir, mpfr) do ( | ||
mkdir %%d\dll\%PLATFORM%\Release | ||
mkdir %%d\lib\%PLATFORM%\Release | ||
|
||
REM copy libraries | ||
copy %LIBRARY_BIN%\%%d.dll %%d\dll\%PLATFORM%\Release\%%d.dll | ||
copy %LIBRARY_LIB%\%%d.lib %%d\dll\%PLATFORM%\Release\%%d.lib | ||
copy %LIBRARY_LIB%\%%d_static.lib %%d\lib\%PLATFORM%\Release\%%d.lib | ||
) | ||
|
||
REM copy headers | ||
xcopy %LIBRARY_INC%\*.h mpir\lib\%PLATFORM%\Release\ /E | ||
xcopy %LIBRARY_INC%\*.h mpir\dll\%PLATFORM%\Release\ /E | ||
|
||
cd %mpc_root%\build.vc14 | ||
|
||
msbuild.exe /p:Platform=%PLATFORM% /p:Configuration=Release /p:PostBuildEvent="" mpc_lib\mpc_lib.vcxproj | ||
msbuild.exe /p:Platform=%PLATFORM% /p:Configuration=Release /p:PostBuildEvent="" mpc_dll\mpc_dll.vcxproj | ||
|
||
copy dll\%PLATFORM%\Release\mpc.lib %LIBRARY_LIB%\mpc.lib | ||
copy dll\%PLATFORM%\Release\mpc.dll %LIBRARY_BIN%\mpc.dll | ||
copy dll\%PLATFORM%\Release\mpc.pdb %LIBRARY_BIN%\mpc.pdb | ||
|
||
copy lib\%PLATFORM%\Release\mpc.lib %LIBRARY_LIB%\mpc_static.lib | ||
|
||
cd %mpc_root% | ||
copy src\mpc.h %LIBRARY_INC%\mpc.h |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,48 @@ | ||
{% set version = "1.0.3" %} | ||
{% set commit = "58fa4d15fff10f26c490518bc0da2b69732e22ee" %} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Could we ping him about getting some tags? What is special/what do we know about this commit? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Nothing special, this is a commit including the MSVC build files that is in between 1.0.3 and the development version. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think the developer is using MPC original git repo and updates his repo from time to time with the MSVC build files rebased |
||
|
||
package: | ||
name: mpc | ||
version: {{ version }} | ||
|
||
source: | ||
fn: mpc-{{ version }}.tar.gz | ||
url: http://www.multiprecision.org/mpc/download/mpc-{{ version }}.tar.gz | ||
sha1: b8be66396c726fdc36ebb0f692ed8a8cca3bcc66 | ||
fn: mpc-{{ version }}.tar.gz # [unix] | ||
url: http://www.multiprecision.org/mpc/download/mpc-{{ version }}.tar.gz # [unix] | ||
sha1: b8be66396c726fdc36ebb0f692ed8a8cca3bcc66 # [unix] | ||
fn: {{ commit }}.zip # [win] | ||
url: https://github.com/BrianGladman/mpc/archive/{{ commit }}.zip # [win] | ||
md5: a3ccbbb17770110427a983638824f31b # [win] | ||
|
||
build: | ||
number: 1 | ||
skip: true # [win] | ||
skip: true # [win and not py35] | ||
features: | ||
- vc14 # [win and py35] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Guessing it doesn't work with older VC versions. Correct? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Correct |
||
|
||
requirements: | ||
build: | ||
- libtool | ||
- m4 | ||
- gmp | ||
- m4 # [unix] | ||
- libtool # [unix] | ||
- gmp # [unix] | ||
- vc 14 # [win] | ||
- mpir # [win] | ||
- mpfr | ||
run: | ||
- gmp | ||
- gmp # [unix] | ||
- mpir # [win] | ||
- vc 14 # [win] | ||
- mpfr | ||
|
||
test: | ||
commands: | ||
- test -f ${PREFIX}/lib/libmpc.a # [unix] | ||
- test -f ${PREFIX}/lib/libmpc.dylib # [osx] | ||
- test -f ${PREFIX}/lib/libmpc.so # [linux] | ||
- if not exist %LIBRARY_INC%\\mpc.h exit 1 # [win] | ||
- if not exist %LIBRARY_LIB%\\mpc.lib exit 1 # [win] | ||
- if not exist %LIBRARY_BIN%\\mpc.dll exit 1 # [win] | ||
- if not exist %LIBRARY_LIB%\\mpc_static.lib exit 1 # [win] | ||
- test -f ${PREFIX}/include/mpc.h # [unix] | ||
- test -f ${PREFIX}/lib/libmpc.a # [unix] | ||
- test -f ${PREFIX}/lib/libmpc.dylib # [osx] | ||
- test -f ${PREFIX}/lib/libmpc.so # [linux] | ||
|
||
about: | ||
home: http://www.multiprecision.org/ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there some sort of test suite that we can run here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, but the script is an interactive python script. I'll have to write it myself for command line use