@@ -99,6 +99,7 @@ pub struct Config {
9999 // Fallback musl-root for all targets
100100 pub musl_root : Option < PathBuf > ,
101101 pub prefix : Option < PathBuf > ,
102+ pub sysconfdir : Option < PathBuf > ,
102103 pub docdir : Option < PathBuf > ,
103104 pub bindir : Option < PathBuf > ,
104105 pub libdir : Option < PathBuf > ,
@@ -166,6 +167,7 @@ struct Build {
166167#[ derive( RustcDecodable , Default , Clone ) ]
167168struct Install {
168169 prefix : Option < String > ,
170+ sysconfdir : Option < String > ,
169171 docdir : Option < String > ,
170172 bindir : Option < String > ,
171173 libdir : Option < String > ,
@@ -317,6 +319,7 @@ impl Config {
317319
318320 if let Some ( ref install) = toml. install {
319321 config. prefix = install. prefix . clone ( ) . map ( PathBuf :: from) ;
322+ config. sysconfdir = install. sysconfdir . clone ( ) . map ( PathBuf :: from) ;
320323 config. docdir = install. docdir . clone ( ) . map ( PathBuf :: from) ;
321324 config. bindir = install. bindir . clone ( ) . map ( PathBuf :: from) ;
322325 config. libdir = install. libdir . clone ( ) . map ( PathBuf :: from) ;
@@ -526,6 +529,9 @@ impl Config {
526529 "CFG_PREFIX" => {
527530 self . prefix = Some ( PathBuf :: from ( value) ) ;
528531 }
532+ "CFG_SYSCONFDIR" => {
533+ self . sysconfdir = Some ( PathBuf :: from ( value) ) ;
534+ }
529535 "CFG_DOCDIR" => {
530536 self . docdir = Some ( PathBuf :: from ( value) ) ;
531537 }
0 commit comments