Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cython
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
Kirill Smelkov
cython
Commits
0060a354
Commit
0060a354
authored
Dec 12, 2014
by
Robert Bradshaw
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #341 from redbrain/fix-dl-import
Emit DL_IMPORT macro for python3
parents
d5b259c5
b1a6a44f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
0 deletions
+7
-0
Cython/Compiler/ModuleNode.py
Cython/Compiler/ModuleNode.py
+7
-0
No files found.
Cython/Compiler/ModuleNode.py
View file @
0060a354
...
@@ -150,6 +150,8 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode):
...
@@ -150,6 +150,8 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode):
h_code
.
putln
(
"#ifndef %s"
%
api_guard
)
h_code
.
putln
(
"#ifndef %s"
%
api_guard
)
h_code
.
putln
(
""
)
h_code
.
putln
(
""
)
self
.
generate_extern_c_macro_definition
(
h_code
)
self
.
generate_extern_c_macro_definition
(
h_code
)
h_code
.
putln
(
""
)
self
.
generate_dl_import_macro
(
h_code
)
if
h_extension_types
:
if
h_extension_types
:
h_code
.
putln
(
""
)
h_code
.
putln
(
""
)
for
entry
in
h_extension_types
:
for
entry
in
h_extension_types
:
...
@@ -671,6 +673,11 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode):
...
@@ -671,6 +673,11 @@ class ModuleNode(Nodes.Node, Nodes.BlockNode):
code
.
putln
(
" #endif"
)
code
.
putln
(
" #endif"
)
code
.
putln
(
"#endif"
)
code
.
putln
(
"#endif"
)
def
generate_dl_import_macro
(
self
,
code
):
code
.
putln
(
"#ifndef DL_IMPORT"
)
code
.
putln
(
" #define DL_IMPORT(_T) _T"
)
code
.
putln
(
"#endif"
)
def
generate_includes
(
self
,
env
,
cimported_modules
,
code
):
def
generate_includes
(
self
,
env
,
cimported_modules
,
code
):
includes
=
[]
includes
=
[]
for
filename
in
env
.
include_files
:
for
filename
in
env
.
include_files
:
...
...
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