private Address layDownCodePointer(Program program, Address entry) {
		int defaultPointerSize = program.getDefaultPointerSize();
		try {
			Data data = program.getListing()
					.createData(entry, PointerDataType.getPointer(null, defaultPointerSize));
			Object value = data.getValue();
			if (value instanceof Address) {
				Address codeLoc = (Address) value;
				if (codeLoc.getOffset() != 0) {
					PseudoDisassembler.setTargetContextForDisassembly(program, codeLoc);
					// align if necessary
					int instructionAlignment = program.getLanguage().getInstructionAlignment();
					if (codeLoc.getOffset() % instructionAlignment != 0) {
						codeLoc = codeLoc.subtract(codeLoc.getOffset() % instructionAlignment);
					}
					return codeLoc;
				}
			}
		}
		catch (CodeUnitInsertionException e) {
			// couldn't create
		}
		return null;
	}
Check for a single external entry point.

@param program - program to check
@param externalCount - count of external entry points found
@param doNowSet - set of functions that are to be done now

@return true if this program has only one external entry point
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/disassembler/EntryPointAnalyzer.java