-
Notifications
You must be signed in to change notification settings - Fork 68
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
33 changed files
with
38 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
graft nes_py/cpp | ||
graft nes_py/nes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
"""The compilation script for this project using SCons.""" | ||
from os import environ | ||
|
||
|
||
# create a separate build directory | ||
VariantDir('build', 'src', duplicate=0) | ||
|
||
|
||
# the compiler and linker flags for the C++ environment | ||
FLAGS = [ | ||
'-std=c++1y', | ||
'-O2', | ||
'-march=native', | ||
'-pipe', | ||
] | ||
|
||
|
||
# Create the C++ environment | ||
ENV = Environment( | ||
ENV=environ, | ||
CXX='clang++', | ||
CPPFLAGS=['-Wno-unused-value'], | ||
CXXFLAGS=FLAGS, | ||
LINKFLAGS=FLAGS, | ||
CPPPATH=['#include'], | ||
) | ||
|
||
|
||
# Locate all the C++ source files | ||
SRC = Glob('build/*.cpp') + Glob('build/*/*.cpp') | ||
# Create a shared library (it will add "lib" to the front automatically) | ||
ENV.SharedLibrary('_nes_env.so', SRC) |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters