1010//! themselves having support libraries. All data over the TCP sockets is in a
1111//! basically custom format suiting our needs.
1212
13- #[ cfg( all ( not( windows) , not ( target_os = "motor" ) ) ) ]
13+ #[ cfg( not( any ( windows, target_os = "motor" , target_os = "uefi ") ) ) ]
1414use std:: fs:: Permissions ;
1515use std:: fs:: { self , File } ;
1616use std:: io:: prelude:: * ;
1717use std:: io:: { self , BufReader } ;
1818use std:: net:: { SocketAddr , TcpListener , TcpStream } ;
19- #[ cfg( all ( not( windows) , not ( target_os = "motor" ) ) ) ]
19+ #[ cfg( not( any ( windows, target_os = "motor" , target_os = "uefi ") ) ) ]
2020use std:: os:: unix:: prelude:: * ;
2121use std:: path:: { Path , PathBuf } ;
2222use std:: process:: { Command , ExitStatus , Stdio } ;
@@ -325,15 +325,15 @@ fn handle_run(socket: TcpStream, work: &Path, tmp: &Path, lock: &Mutex<()>, conf
325325 ] ) ) ;
326326}
327327
328- #[ cfg( all ( not( windows) , not ( target_os = "motor" ) ) ) ]
328+ #[ cfg( not( any ( windows, target_os = "motor" , target_os = "uefi ") ) ) ]
329329fn get_status_code ( status : & ExitStatus ) -> ( u8 , i32 ) {
330330 match status. code ( ) {
331331 Some ( n) => ( 0 , n) ,
332332 None => ( 1 , status. signal ( ) . unwrap ( ) ) ,
333333 }
334334}
335335
336- #[ cfg( any( windows, target_os = "motor" ) ) ]
336+ #[ cfg( any( windows, target_os = "motor" , target_os = "uefi" ) ) ]
337337fn get_status_code ( status : & ExitStatus ) -> ( u8 , i32 ) {
338338 ( 0 , status. code ( ) . unwrap ( ) )
339339}
@@ -359,11 +359,11 @@ fn recv<B: BufRead>(dir: &Path, io: &mut B) -> PathBuf {
359359 dst
360360}
361361
362- #[ cfg( all ( not( windows) , not ( target_os = "motor" ) ) ) ]
362+ #[ cfg( not( any ( windows, target_os = "motor" , target_os = "uefi ") ) ) ]
363363fn set_permissions ( path : & Path ) {
364364 t ! ( fs:: set_permissions( & path, Permissions :: from_mode( 0o755 ) ) ) ;
365365}
366- #[ cfg( any( windows, target_os = "motor" ) ) ]
366+ #[ cfg( any( windows, target_os = "motor" , target_os = "uefi" ) ) ]
367367fn set_permissions ( _path : & Path ) { }
368368
369369fn my_copy ( src : & mut dyn Read , which : u8 , dst : & Mutex < dyn Write > ) {
0 commit comments