private void runPdbExe(String pdbExeLocation, File pdbParentDir, String pdbName,
			String currentFilePath) throws IOException, InterruptedException {

		ProcessBuilder builder = new ProcessBuilder(pdbExeLocation, currentFilePath);
		File createdFile = new File(pdbParentDir, pdbName + ".xml");
		builder.redirectOutput(createdFile);

		Process currentProcess = builder.start();
		StringBuilder strBuilder = new StringBuilder();

		BufferedReader reader =
			new BufferedReader(new InputStreamReader(currentProcess.getErrorStream()));
		String line = null;

		while ((line = reader.readLine()) != null) {
			strBuilder.append(line);
			strBuilder.append(System.getProperty("line.separator"));
		}

		reader.close();

		int exitValue = currentProcess.waitFor();
		String errorMessage = strBuilder.toString();

		if (errorMessage.length() > 0) {
			if (createdFile.isFile()) {
				createdFile.delete();
			}

			throw new IOException("At file '" + pdbName + "':\n" + errorMessage);
		}

		if (exitValue != 0) {
			if (createdFile.isFile()) {
				createdFile.delete();
			}

			throw new IOException(
				"At file '" + pdbName + "':\nAbnormal termination of 'pdb.exe' process.");
		}
	}
Asks user for a single .pdb file or a directory that contains .pdb files (search for
files is recursive).

Parses each .pdb file and creates a corresponding .pdb.xml file in the same location as
the original file. The .pdb.xml files can be used to apply debugging information when
running Ghidra on non-Windows systems.

This script can only be run on Windows and using the headed (GUI) version of Ghidra.
Ghidra/Features/Base/ghidra_scripts/CreatePdbXmlFilesScript.java