Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yara-python
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
fact-depend
yara-python
Commits
5ce5eacd
Unverified
Commit
5ce5eacd
authored
May 15, 2020
by
Victor M. Alvarez
Committed by
GitHub
May 15, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Force C99 while compiling statically. (#145)
parent
f2358936
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
2 deletions
+10
-2
setup.py
setup.py
+9
-1
yara
yara
+1
-1
No files found.
setup.py
View file @
5ce5eacd
...
@@ -30,7 +30,6 @@ import tempfile
...
@@ -30,7 +30,6 @@ import tempfile
import
shutil
import
shutil
import
subprocess
import
subprocess
OPTIONS
=
[
OPTIONS
=
[
(
'dynamic-linking'
,
None
,
'link dynamically against libyara'
),
(
'dynamic-linking'
,
None
,
'link dynamically against libyara'
),
(
'enable-cuckoo'
,
None
,
'enable "cuckoo" module'
),
(
'enable-cuckoo'
,
None
,
'enable "cuckoo" module'
),
...
@@ -182,7 +181,9 @@ class BuildExtCommand(build_ext):
...
@@ -182,7 +181,9 @@ class BuildExtCommand(build_ext):
building_for_openbsd
=
'openbsd'
in
self
.
plat_name
# need testing
building_for_openbsd
=
'openbsd'
in
self
.
plat_name
# need testing
if
building_for_linux
:
if
building_for_linux
:
module
.
define_macros
.
append
((
'_GNU_SOURCE'
,
'1'
))
module
.
define_macros
.
append
((
'USE_LINUX_PROC'
,
'1'
))
module
.
define_macros
.
append
((
'USE_LINUX_PROC'
,
'1'
))
module
.
extra_compile_args
.
append
(
'-std=c99'
)
elif
building_for_windows
:
elif
building_for_windows
:
module
.
define_macros
.
append
((
'USE_WINDOWS_PROC'
,
'1'
))
module
.
define_macros
.
append
((
'USE_WINDOWS_PROC'
,
'1'
))
module
.
define_macros
.
append
((
'_CRT_SECURE_NO_WARNINGS'
,
'1'
))
module
.
define_macros
.
append
((
'_CRT_SECURE_NO_WARNINGS'
,
'1'
))
...
@@ -192,26 +193,33 @@ class BuildExtCommand(build_ext):
...
@@ -192,26 +193,33 @@ class BuildExtCommand(build_ext):
module
.
libraries
.
append
(
'crypt32'
)
module
.
libraries
.
append
(
'crypt32'
)
module
.
libraries
.
append
(
'ws2_32'
)
module
.
libraries
.
append
(
'ws2_32'
)
elif
building_for_osx
:
elif
building_for_osx
:
module
.
define_macros
.
append
((
'_GNU_SOURCE'
,
'1'
))
module
.
define_macros
.
append
((
'USE_MACH_PROC'
,
'1'
))
module
.
define_macros
.
append
((
'USE_MACH_PROC'
,
'1'
))
module
.
extra_compile_args
.
append
(
'-std=c99'
)
module
.
include_dirs
.
append
(
'/usr/local/opt/openssl/include'
)
module
.
include_dirs
.
append
(
'/usr/local/opt/openssl/include'
)
module
.
include_dirs
.
append
(
'/opt/local/include'
)
module
.
include_dirs
.
append
(
'/opt/local/include'
)
module
.
library_dirs
.
append
(
'/opt/local/lib'
)
module
.
library_dirs
.
append
(
'/opt/local/lib'
)
module
.
include_dirs
.
append
(
'/usr/local/include'
)
module
.
include_dirs
.
append
(
'/usr/local/include'
)
module
.
library_dirs
.
append
(
'/usr/local/lib'
)
module
.
library_dirs
.
append
(
'/usr/local/lib'
)
elif
building_for_freebsd
:
elif
building_for_freebsd
:
module
.
define_macros
.
append
((
'_GNU_SOURCE'
,
'1'
))
module
.
define_macros
.
append
((
'USE_FREEBSD_PROC'
,
'1'
))
module
.
define_macros
.
append
((
'USE_FREEBSD_PROC'
,
'1'
))
module
.
include_dirs
.
append
(
'/opt/local/include'
)
module
.
include_dirs
.
append
(
'/opt/local/include'
)
module
.
library_dirs
.
append
(
'/opt/local/lib'
)
module
.
library_dirs
.
append
(
'/opt/local/lib'
)
module
.
include_dirs
.
append
(
'/usr/local/include'
)
module
.
include_dirs
.
append
(
'/usr/local/include'
)
module
.
library_dirs
.
append
(
'/usr/local/lib'
)
module
.
library_dirs
.
append
(
'/usr/local/lib'
)
elif
building_for_openbsd
:
elif
building_for_openbsd
:
module
.
define_macros
.
append
((
'_GNU_SOURCE'
,
'1'
))
module
.
define_macros
.
append
((
'USE_OPENBSD_PROC'
,
'1'
))
module
.
define_macros
.
append
((
'USE_OPENBSD_PROC'
,
'1'
))
module
.
extra_compile_args
.
append
(
'-std=c99'
)
module
.
include_dirs
.
append
(
'/opt/local/include'
)
module
.
include_dirs
.
append
(
'/opt/local/include'
)
module
.
library_dirs
.
append
(
'/opt/local/lib'
)
module
.
library_dirs
.
append
(
'/opt/local/lib'
)
module
.
include_dirs
.
append
(
'/usr/local/include'
)
module
.
include_dirs
.
append
(
'/usr/local/include'
)
module
.
library_dirs
.
append
(
'/usr/local/lib'
)
module
.
library_dirs
.
append
(
'/usr/local/lib'
)
else
:
else
:
module
.
define_macros
.
append
((
'_GNU_SOURCE'
,
'1'
))
module
.
define_macros
.
append
((
'USE_NO_PROC'
,
'1'
))
module
.
define_macros
.
append
((
'USE_NO_PROC'
,
'1'
))
module
.
extra_compile_args
.
append
(
'-std=c99'
)
if
has_function
(
'memmem'
):
if
has_function
(
'memmem'
):
module
.
define_macros
.
append
((
'HAVE_MEMMEM'
,
'1'
))
module
.
define_macros
.
append
((
'HAVE_MEMMEM'
,
'1'
))
...
...
yara
@
b5378bfb
Subproject commit
f4a5daab94d77f7ad4c404634976ddd4c7bd9da6
Subproject commit
b5378bfb3d319cc20eab311c85d38ccc529baee8
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