Skip to content

Commit a84452a

Browse files
committed
fix sysconfigdata
1 parent 73e1c38 commit a84452a

File tree

2 files changed

+17
-1
lines changed

2 files changed

+17
-1
lines changed

Lib/test/test_sysconfig.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -447,7 +447,6 @@ def test_main(self):
447447
_main()
448448
self.assertTrue(len(output.getvalue().split('\n')) > 0)
449449

450-
@unittest.expectedFailure # TODO: RUSTPYTHON
451450
@unittest.skipIf(sys.platform == "win32", "Does not apply to Windows")
452451
def test_ldshared_value(self):
453452
ldflags = sysconfig.get_config_var('LDFLAGS')

crates/vm/src/stdlib/sysconfigdata.rs

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
// spell-checker: words LDSHARED ARFLAGS CPPFLAGS CCSHARED BASECFLAGS BLDSHARED
2+
13
pub(crate) use _sysconfigdata::make_module;
24

35
#[pymodule]
@@ -18,6 +20,21 @@ pub(crate) mod _sysconfigdata {
1820
"MULTIARCH" => MULTIARCH,
1921
// enough for tests to stop expecting urandom() to fail after restricting file resources
2022
"HAVE_GETRANDOM" => 1,
23+
// Compiler configuration for native extension builds
24+
"CC" => "cc",
25+
"CXX" => "c++",
26+
"CFLAGS" => "",
27+
"CPPFLAGS" => "",
28+
"LDFLAGS" => "",
29+
"LDSHARED" => "cc -shared",
30+
"CCSHARED" => "",
31+
"SHLIB_SUFFIX" => ".so",
32+
"SO" => ".so",
33+
"AR" => "ar",
34+
"ARFLAGS" => "rcs",
35+
"OPT" => "",
36+
"BASECFLAGS" => "",
37+
"BLDSHARED" => "cc -shared",
2138
}
2239
include!(concat!(env!("OUT_DIR"), "/env_vars.rs"));
2340
vars

0 commit comments

Comments
 (0)