@@ -855,6 +855,8 @@ pub struct TargetOptions {
855
855
/// the functions in the executable are not randomized and can be used
856
856
/// during an exploit of a vulnerability in any code.
857
857
pub position_independent_executables: bool,
858
+ /// Executables that are both statically linked and position-independent are supported.
859
+ pub static_position_independent_executables: bool,
858
860
/// Determines if the target always requires using the PLT for indirect
859
861
/// library calls or not. This controls the default value of the `-Z plt` flag.
860
862
pub needs_plt: bool,
@@ -1028,6 +1030,7 @@ impl Default for TargetOptions {
1028
1030
has_rpath: false,
1029
1031
no_default_libraries: true,
1030
1032
position_independent_executables: false,
1033
+ static_position_independent_executables: false,
1031
1034
needs_plt: false,
1032
1035
relro_level: RelroLevel::None,
1033
1036
pre_link_objects: Default::default(),
@@ -1432,6 +1435,7 @@ impl Target {
1432
1435
key!(has_rpath, bool);
1433
1436
key!(no_default_libraries, bool);
1434
1437
key!(position_independent_executables, bool);
1438
+ key!(static_position_independent_executables, bool);
1435
1439
key!(needs_plt, bool);
1436
1440
key!(relro_level, RelroLevel)?;
1437
1441
key!(archive_format);
@@ -1663,6 +1667,7 @@ impl ToJson for Target {
1663
1667
target_option_val!(has_rpath);
1664
1668
target_option_val!(no_default_libraries);
1665
1669
target_option_val!(position_independent_executables);
1670
+ target_option_val!(static_position_independent_executables);
1666
1671
target_option_val!(needs_plt);
1667
1672
target_option_val!(relro_level);
1668
1673
target_option_val!(archive_format);
0 commit comments