Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
C
CrysFML
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Scientific Software
CrysFML
Commits
6ddf9e62
Unverified
Commit
6ddf9e62
authored
3 years ago
by
Simon Ward
Browse files
Options
Downloads
Patches
Plain Diff
More Fortran fixes
parent
169f8af0
No related branches found
No related tags found
2 merge requests
!18
Feature python api build wheels
,
!17
Feature - Python_api wheels
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
.github/workflows/build_variants.yml
+19
-12
19 additions, 12 deletions
.github/workflows/build_variants.yml
setup.py
+3
-10
3 additions, 10 deletions
setup.py
with
22 additions
and
22 deletions
.github/workflows/build_variants.yml
+
19
−
12
View file @
6ddf9e62
...
...
@@ -24,7 +24,7 @@ jobs:
strategy
:
max-parallel
:
4
matrix
:
python-version
:
[
3.6
,
3.7
,
3.8
,
3.9
]
python-version
:
[
'
3.6
'
,
'
3.7
'
,
'
3.8
'
,
'
3.9
'
,
'
3.10'
]
os
:
[
macos-10.15
,
macos-11.0
,
windows-latest
]
gcc_v
:
[
10
]
# Version of GFortran we want to use.
exclude
:
...
...
@@ -47,22 +47,29 @@ jobs:
with
:
python-version
:
${{matrix.python-version}}
# - name: Set Compiler (OSX)
# run: |
# echo "FC=gfortran-${{ matrix.gcc_v }}" >> $GITHUB_ENV
# echo "CC=gcc-${{ matrix.gcc_v }}" >> $GITHUB_ENV
-
name
:
Install cmake
run
:
pip3 install cmake
delocate
run
:
pip3 install cmake
-
name
:
Build CFML
run
:
pip wheel ./ --no-deps -w ./dist/
-
name
:
Build CFML (Windows)
if
:
contains(matrix.os, 'windows')
env
:
FC
:
gfortran
CC
:
gcc
run
:
pip3 wheel ./ --no-deps -w ./dist/
-
name
:
Fix Wheel
-
name
:
Build CFML (OSX)
if
:
contains(matrix.os, 'macos')
run
:
delocate-wheel -w fixed_wheels -v ./dist/*.whl
env
:
FC
:
gfortran-${{ matrix.gcc_v }}
CC
:
gcc-${{ matrix.gcc_v }}
run
:
|
pip3 wheel ./ --no-deps -w ./dist/
pip3 install delocate
delocate-wheel -w fixed_wheels -v ./dist/*.whl
mv ./dist ./old
mv ./fixed_wheels ./dist
-
uses
:
actions/upload-artifact@v2
with
:
name
:
CrysFML - ${{ matrix.os }} - Python ${{ matrix.python-version }}
path
:
./fixed_wheels/*.whl
\ No newline at end of file
path
:
./dist/*.whl
\ No newline at end of file
This diff is collapsed.
Click to expand it.
setup.py
+
3
−
10
View file @
6ddf9e62
...
...
@@ -14,17 +14,10 @@ import shutil
BITS
=
struct
.
calcsize
(
"
P
"
)
*
8
PACKAGE_NAME
=
"
crysfml_api
"
SOURCE_DIR
=
'
.
'
def
cmd_exists
(
cmd
):
return
shutil
.
which
(
cmd
)
is
not
None
COMPILER
=
'
gfortran
'
if
not
cmd_exists
(
COMPILER
):
versions
=
[
10
,
9
,
8
]
for
version
in
versions
:
COMPILER
=
f
'
gfortran-
{
version
}
'
if
cmd_exists
(
COMPILER
):
break
if
os
.
environ
.
get
(
'
FC
'
,
False
):
COMPILER
=
os
.
environ
.
get
(
'
FC
'
)
print
(
f
'
Compiler set to:
{
COMPILER
}
'
)
# We can use cmake provided from pip which (normally) gets installed at /bin
# Except that in the manylinux builds it's placed at /opt/python/[version]/bin/
...
...
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