/***************************************************************************************** * * Reads the Ghidra/application.properties file and sets properties for the version, * release name, and distro prefix (ghidira_) * *****************************************************************************************/ def ghidraProps = new Properties() file("Ghidra/application.properties").withReader { reader -> ghidraProps.load(reader) version = ghidraProps.getProperty('application.version') project.ext.RELEASE_VERSION = version project.ext.RELEASE_NAME = ghidraProps.getProperty('application.release.name') project.ext.DISTRO_PREFIX = "ghidra_${version}" project.ext.JAVA_COMPILER = ghidraProps.getProperty('application.java.compiler') // Build dates may or may not be already present in the application.properties file. // If they are not present, we will set the dates so Gradle can use them, and we will // indicate that the build dates need to be injected into the build's final // application.properties file when it is copied. project.ext.BUILD_DATE = ghidraProps.getProperty('application.build.date') project.ext.BUILD_DATE_SHORT = ghidraProps.getProperty('application.build.date.short') project.ext.BUILD_DATES_NEEDED = false if (BUILD_DATE == null) { project.ext.BUILD_DATE = getCurrentDateTimeLong() project.ext.BUILD_DATE_SHORT = getCurrentDate() project.ext.BUILD_DATES_NEEDED = true } }