Skip to content

Commit e016f4e

Browse files
Force SCons to use GCC when building .c files (algorithm-archivists#928)
1 parent 71e7bde commit e016f4e

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

SConstruct

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,14 @@ Currently, the aim is to provide a way to compile or copy the implementation fil
88
To run the compilation for all implmeentations in one language, e.g. Rust, run the command `scons build/c`, and the resulting executables will be available in the `cuild/c` directory, each in their respective algorithm directory, containing the executable."""
99

1010
from pathlib import Path
11+
import os
1112

12-
env = Environment()
13+
env = Environment(ENV={'PATH': os.environ['PATH']})
14+
15+
env['CC'] = 'gcc'
16+
for tool in ['gcc','gnulink']:
17+
env.Tool(tool)
18+
env['CCFLAGS'] = ''
1319

1420
# Add other languages here when you want to add language targets
1521
languages = ['c']

0 commit comments

Comments
 (0)