equal
deleted
inserted
replaced
27 |
27 |
28 import java.io.File; |
28 import java.io.File; |
29 import java.io.IOException; |
29 import java.io.IOException; |
30 import java.math.BigInteger; |
30 import java.math.BigInteger; |
31 import java.text.MessageFormat; |
31 import java.text.MessageFormat; |
32 import java.util.Arrays; |
|
33 import java.util.Collection; |
|
34 import java.util.HashMap; |
32 import java.util.HashMap; |
35 import java.util.Map; |
33 import java.util.Map; |
36 import java.util.Optional; |
34 import java.util.Optional; |
37 import java.util.ResourceBundle; |
35 import java.util.ResourceBundle; |
38 |
36 |
276 if (signingIdentity == null) { |
274 if (signingIdentity == null) { |
277 throw new ConfigException( |
275 throw new ConfigException( |
278 I18N.getString("error.explicit-sign-no-cert"), |
276 I18N.getString("error.explicit-sign-no-cert"), |
279 I18N.getString("error.explicit-sign-no-cert.advice")); |
277 I18N.getString("error.explicit-sign-no-cert.advice")); |
280 } |
278 } |
|
279 |
|
280 // Signing will not work without Xcode with command line developer tools |
|
281 try { |
|
282 ProcessBuilder pb = new ProcessBuilder("xcrun", "--help"); |
|
283 Process p = pb.start(); |
|
284 int code = p.waitFor(); |
|
285 if (code != 0) { |
|
286 throw new ConfigException( |
|
287 I18N.getString("error.no.xcode.signing"), |
|
288 I18N.getString("error.no.xcode.signing.advice")); |
|
289 } |
|
290 } catch (IOException | InterruptedException ex) { |
|
291 throw new ConfigException(ex); |
|
292 } |
281 } |
293 } |
282 |
294 |
283 return true; |
295 return true; |
284 } |
296 } |
285 |
297 |