Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
pyodide
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
pyodide
Commits
3b429e61
Commit
3b429e61
authored
Sep 21, 2018
by
Roman Yurchak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Address review comments
parent
0c6b653f
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
38 additions
and
50 deletions
+38
-50
Makefile.envs
Makefile.envs
+0
-1
bin/pyodide
bin/pyodide
+7
-0
packages/Makefile
packages/Makefile
+1
-1
pyodide_build/__main__.py
pyodide_build/__main__.py
+1
-1
pyodide_build/buildpkg.py
pyodide_build/buildpkg.py
+1
-2
pyodide_build/pywasmcross.py
pyodide_build/pywasmcross.py
+28
-19
setup.py
setup.py
+0
-26
No files found.
Makefile.envs
View file @
3b429e61
export
PATH
:=
$(PYODIDE_ROOT)
/ccache:
$(PYODIDE_ROOT)
/emsdk/emsdk:
$(PYODIDE_ROOT)
/emsdk/emsdk/clang/tag-e1.38.10/build_tag-e1.38.10_64/bin:
$(PYODIDE_ROOT)
/emsdk/emsdk/node/8.9.1_64bit/bin:
$(PYODIDE_ROOT)
/emsdk/emsdk/emscripten/tag-1.38.10:
$(PYODIDE_ROOT)
/emsdk/emsdk/binaryen/tag-1.38.10_64bit_binaryen/bin:
$(PATH)
export
PYTHONPATH
:=
$(PYTHONPATH)
:
$(PYODIDE_ROOT)
/
export
EMSDK
=
$(PYODIDE_ROOT)
/emsdk/emsdk
export
EM_CONFIG
=
$(PYODIDE_ROOT)
/emsdk/emsdk/.emscripten
...
...
bin/pyodide
0 → 100755
View file @
3b429e61
#!/bin/sh
# get the absolute path to the root directory
ROOTDIR
=
"
$(
cd
${
BASH_SOURCE
%/*
}
/../
;
pwd
)
"
;
export
PYTHONPATH
=
"
${
PYTHONPATH
}
:
${
ROOTDIR
}
"
python
-m
pyodide_build
"
$@
"
packages/Makefile
View file @
3b429e61
...
...
@@ -2,7 +2,7 @@ PYODIDE_ROOT=$(abspath ..)
include
../Makefile.envs
all
:
python
-m
pyodide_build
buildall
.
../build
\
../bin/pyodide
buildall
.
../build
\
--ldflags
=
"
$(SIDE_LDFLAGS)
"
--host
=
$(HOSTPYTHONROOT)
--target
=
$(TARGETPYTHONROOT)
clean
:
...
...
pyodide_build/__main__.py
View file @
3b429e61
...
...
@@ -7,7 +7,7 @@ from . import pywasmcross
def
main
():
main_parser
=
argparse
.
ArgumentParser
()
main_parser
=
argparse
.
ArgumentParser
(
prog
=
'pyodide'
)
subparsers
=
main_parser
.
add_subparsers
(
help
=
'action'
)
for
command_name
,
module
in
((
"buildpkg"
,
buildpkg
),
...
...
pyodide_build/buildpkg.py
View file @
3b429e61
...
...
@@ -85,8 +85,7 @@ def compile(path, srcpath, pkg, args):
try
:
subprocess
.
run
([
str
(
Path
(
args
.
host
)
/
'bin'
/
'python3'
),
'-m'
,
'pyodide_build'
,
'pywasmcross'
,
'-m'
,
'pyodide_build'
,
'pywasmcross'
,
'--cflags'
,
args
.
cflags
+
' '
+
pkg
.
get
(
'build'
,
{}).
get
(
'cflags'
,
''
),
...
...
pyodide_build/pywasmcross.py
View file @
3b429e61
...
...
@@ -208,6 +208,11 @@ def build_wrap(args):
def
make_parser
(
parser
):
basename
=
Path
(
sys
.
argv
[
0
]).
name
if
basename
in
symlinks
:
# skip parsing of all arguments
parser
.
_actions
=
[]
else
:
parser
.
description
=
(
'Cross compile a Python distutils package. '
'Run from the root directory of the package
\
'
s source'
)
...
...
@@ -226,7 +231,7 @@ def make_parser(parser):
return
parser
def
main
(
args
,
unknown
=
None
):
def
main
(
args
):
basename
=
Path
(
sys
.
argv
[
0
]).
name
if
basename
in
symlinks
:
collect_args
(
basename
)
...
...
@@ -235,6 +240,10 @@ def main(args, unknown=None):
if
__name__
==
'__main__'
:
basename
=
Path
(
sys
.
argv
[
0
]).
name
if
basename
in
symlinks
:
main
(
None
)
else
:
parser
=
make_parser
(
argparse
.
ArgumentParser
())
args
,
unknown
=
parser
.
parse_known
_args
()
main
(
args
,
unknown
)
args
=
parser
.
parse
_args
()
main
(
args
)
setup.py
deleted
100644 → 0
View file @
0c6b653f
from
setuptools
import
setup
import
sys
from
pyodide_build
import
__version__
if
'install'
in
sys
.
argv
or
'bdist_wheel'
in
sys
.
argv
:
print
(
"Error: pyodode_build is currently not fully standalone, "
"and can only be installed in development mode. Use:
\
n
"
" pip install -e .
\
n
"
"to install it."
)
sys
.
exit
(
1
)
with
open
(
'README.md'
,
'rt'
)
as
fh
:
LONG_DESCRIPTION
=
fh
.
read
()
setup
(
name
=
'pyodide_build'
,
version
=
__version__
,
description
=
'pyodide builder'
,
entry_points
=
{
'console_scripts'
:
[
'pyodide = pyodide_build.__main__:main'
]},
url
=
"https://github.com/iodide-project/pyodide"
,
license
=
'MPL'
,
packages
=
[
'pyodide_build'
])
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment