Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pyopencl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Alexandru Fikl
pyopencl
Commits
1c18bbef
Unverified
Commit
1c18bbef
authored
6 years ago
by
Andreas Klöckner
Committed by
GitHub
6 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Revert "Revert "[WIP] Wheels: Use ocl-icd and bundle license""
parent
9bd59c57
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.travis.yml
+23
-0
23 additions, 0 deletions
.travis.yml
travis/build-wheels.sh
+58
-0
58 additions, 0 deletions
travis/build-wheels.sh
travis/fix-wheel.py
+22
-0
22 additions, 0 deletions
travis/fix-wheel.py
with
103 additions
and
0 deletions
.travis.yml
0 → 100644
+
23
−
0
View file @
1c18bbef
notifications
:
email
:
false
if
:
tag IS present
matrix
:
include
:
-
sudo
:
required
services
:
-
docker
env
:
-
DOCKER_IMAGE=quay.io/pypa/manylinux1_x86_64
-
sudo
:
required
services
:
-
docker
env
:
-
DOCKER_IMAGE=quay.io/pypa/manylinux1_i686
-
PRE_CMD=linux32
install
:
-
docker pull $DOCKER_IMAGE
script
:
-
pwd
-
ls -la
-
docker run --rm -v `pwd`:/io -e TWINE_USERNAME -e TWINE_PASSWORD $DOCKER_IMAGE $PRE_CMD /io/travis/build-wheels.sh
-
ls wheelhouse/
This diff is collapsed.
Click to expand it.
travis/build-wheels.sh
0 → 100755
+
58
−
0
View file @
1c18bbef
#!/bin/bash
set
-e
-x
cd
/io
mkdir
-p
deps
cd
deps
yum
install
-y
git cmake yum wget
wget http://cache.ruby-lang.org/pub/ruby/2.1/ruby-2.1.2.tar.gz
tar
-xvf
ruby-2.1.2.tar.gz
cd
ruby-2.1.2
./configure
make
-j4
make
install
cd
..
rm
-rf
ruby-2.1.2
git clone
--branch
v2.2.12 https://github.com/OCL-dev/ocl-icd
cd
ocl-icd
wget https://raw.githubusercontent.com/conda-forge/ocl-icd-feedstock/master/recipe/install-headers.patch
--no-check-certificate
git apply install-headers.patch
autoreconf
-i
chmod
+x configure
./configure
--prefix
=
/usr
make
-j4
make
install
cd
/io
# Compile wheels
for
PYBIN
in
/opt/python/
*
/bin
;
do
"
${
PYBIN
}
/pip"
install
numpy pybind11 mako
"
${
PYBIN
}
/pip"
wheel /io/
-w
wheelhouse/
done
# Bundle external shared libraries into the wheels
for
whl
in
wheelhouse/pyopencl
*
.whl
;
do
auditwheel repair
"
$whl
"
-w
/io/wheelhouse/
done
# Bundle license files
/opt/python/cp37-cp37m/bin/pip
install
delocate
/opt/python/cp37-cp37m/bin/python /io/travis/fix-wheel.py /io/deps/ocl-icd/COPYING
/opt/python/cp37-cp37m/bin/pip
install
twine
for
WHEEL
in
/io/wheelhouse/pyopencl
*
.whl
;
do
# dev
# /opt/python/cp37-cp37m/bin/twine upload \
# --skip-existing \
# --repository-url https://test.pypi.org/legacy/ \
# -u "${TWINE_USERNAME}" -p "${TWINE_PASSWORD}" \
# "${WHEEL}"
# prod
/opt/python/cp37-cp37m/bin/twine upload
\
--skip-existing
\
-u
"
${
TWINE_USERNAME
}
"
-p
"
${
TWINE_PASSWORD
}
"
\
"
${
WHEEL
}
"
done
This diff is collapsed.
Click to expand it.
travis/fix-wheel.py
0 → 100644
+
22
−
0
View file @
1c18bbef
import
sys
import
os.path
import
shutil
from
glob
import
glob
from
delocate
import
wheeltools
def
add_library
(
paths
):
wheel_fnames
=
glob
(
'
/io/wheelhouse/pyopencl*.whl
'
)
for
fname
in
wheel_fnames
:
print
(
'
Processing
'
,
fname
)
with
wheeltools
.
InWheel
(
fname
,
fname
):
for
lib_path
in
paths
:
shutil
.
copy2
(
lib_path
,
os
.
path
.
join
(
'
pyopencl
'
,
'
.libs
'
))
def
main
():
args
=
list
(
sys
.
argv
)
args
.
pop
(
0
)
add_library
(
args
)
if
__name__
==
'
__main__
'
:
main
()
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment