Skip to content

Commit f5f4752

Browse files
committed
Removed automatic deletion of generated C/C++ files
This was to force the entire project to be "recythonized" because sometimes changes (in the C headers) wouldn't trigger a regeneration of C/C++ files. Use 'python setup.py clean' instead.
1 parent f996224 commit f5f4752

File tree

1 file changed

+0
-20
lines changed

1 file changed

+0
-20
lines changed

setup.py

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -70,26 +70,6 @@ def cython_sources(self, sources, extension):
7070

7171
modules = ['system', 'window', 'graphics', 'audio', 'network']
7272

73-
sources = {module: os.path.join('src', 'sfml', module + '.pyx') for module in modules}
74-
headers = {module: os.path.join('include', 'pysfml', module + '.h') for module in modules}
75-
api_headers = {module: os.path.join('include', 'pysfml', module + '._api.h') for module in modules}
76-
77-
include_path = os.path.join('include', 'pysfml')
78-
source_path = os.path.join('src', 'sfml')
79-
80-
# clean the directory (remove generated C++ files by Cython)
81-
def remove_if_exist(filename):
82-
if os.path.isfile(filename):
83-
try:
84-
os.remove(filename)
85-
except OSError:
86-
pass
87-
88-
for module in modules:
89-
remove_if_exist(os.path.join(include_path, module, module + '.h'))
90-
remove_if_exist(os.path.join(include_path, module, module + '._api.h'))
91-
remove_if_exist(os.path.join(source_path, module, module + '.cpp'))
92-
9373
# use extlibs on Windows only
9474
if platform.system() == 'Windows':
9575
extension = lambda name, files, libs: Extension(

0 commit comments

Comments
 (0)