mirror of
https://github.com/NationalSecurityAgency/ghidra
synced 2024-08-27 21:10:26 +00:00
Merge branch 'GP-0_ryanmkurtz_PR-6249_ByThePowerOfScience_single-jar-src'
This commit is contained in:
commit
586fc9efcd
|
@ -327,7 +327,7 @@ public class GhidraJarBuilder implements GhidraLaunchable {
|
|||
Collections.sort(moduleList);
|
||||
|
||||
for (ApplicationModule module : moduleList) {
|
||||
File srcDir = new File(module.getModuleDir(), "src");
|
||||
File srcDir = new File(module.getModuleDir(), "lib");
|
||||
File srcZipFileForModule = new File(srcDir, module.getName() + "-src.zip");
|
||||
if (srcZipFileForModule.exists()) {
|
||||
writeModuleSrcZipToOverallSrcZip(zip, srcZipFileForModule);
|
||||
|
@ -337,12 +337,17 @@ public class GhidraJarBuilder implements GhidraLaunchable {
|
|||
wroteToZip |= writeZipRecursively(zip, srcDir.getAbsolutePath(), srcDir);
|
||||
}
|
||||
}
|
||||
if (wroteToZip) {
|
||||
if (!wroteToZip) {
|
||||
System.out
|
||||
.println("Can't create source zip! Has source been downloaded and installed?");
|
||||
// zip.close reports error if nothing has been written to it
|
||||
}
|
||||
try {
|
||||
// zip.close may report error if nothing has been written to it
|
||||
zip.close();
|
||||
}
|
||||
catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
private void writeModuleSrcZipToOverallSrcZip(Zip zip, File srcZipFileForModule)
|
||||
|
|
Loading…
Reference in a new issue