Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
typon-compiler
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
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
typon
typon-compiler
Commits
bdccf8df
Commit
bdccf8df
authored
Nov 02, 2023
by
Tom Niget
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use current Python version for build flag
parent
47c8827c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
typon/trans/main.py
typon/trans/main.py
+4
-1
No files found.
typon/trans/main.py
View file @
bdccf8df
...
@@ -7,6 +7,7 @@ typon in.py [-o out.py] [-v]
...
@@ -7,6 +7,7 @@ typon in.py [-o out.py] [-v]
import
argparse
import
argparse
import
logging
import
logging
import
os
from
pathlib
import
Path
from
pathlib
import
Path
import
sys
import
sys
...
@@ -50,9 +51,11 @@ def main():
...
@@ -50,9 +51,11 @@ def main():
pybind11
.
commands
.
get_include
()
pybind11
.
commands
.
get_include
()
]
]
include_dirs
=
list
(
dict
.
fromkeys
(
include_dirs
))
include_dirs
=
list
(
dict
.
fromkeys
(
include_dirs
))
# get python major and minor version
python_version
=
sys
.
version_info
cpp_flags
=
[
cpp_flags
=
[
*
[
"-I"
+
d
for
d
in
include_dirs
],
*
[
"-I"
+
d
for
d
in
include_dirs
],
"-pthread"
,
"-luring"
,
"-lfmt"
,
"-lssl"
,
"-lcrypto"
,
"-lpython3.10
"
,
"-std=c++20"
"-pthread"
,
"-luring"
,
"-lfmt"
,
"-lssl"
,
"-lcrypto"
,
f"-lpython
{
python_version
.
major
}
.
{
python_version
.
minor
}
"
,
"-std=c++20"
]
]
if
args
.
extension
:
if
args
.
extension
:
cpp_flags
.
extend
((
"-DTYPON_EXTENSION"
,
"-fPIC"
,
"-shared"
))
cpp_flags
.
extend
((
"-DTYPON_EXTENSION"
,
"-fPIC"
,
"-shared"
))
...
...
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