mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
[build] Fix doxygen builds on apple CPUs (#8282)
Caused by the doxygen gradle plugin attempting to download 1.10.0 (presumably its default version) from artifactory because the 1.12.0 config is only applied on x86_64 platforms. Just fixing that isn't enough, however; on mac, the plugin would fail to extract the dmg. We need to fall back to a global installation on the PATH for the plugin to find, preferentially using that instead of a failed attempt to download and extract the dmg.
This commit is contained in:
@@ -52,12 +52,16 @@ doxygen {
|
||||
// See below maven and https://doxygen.nl/download.html for provided binaries
|
||||
// Ensure theme.css (from https://github.com/jothepro/doxygen-awesome-css) is compatible with
|
||||
// doxygen version when updating
|
||||
executables {
|
||||
doxygen {
|
||||
// Note: has no effect if not on an x86_64 platform - you need to have a global install available on your
|
||||
// PATH for the doxygen plugin to run
|
||||
executableByVersion('1.12.0')
|
||||
|
||||
String arch = System.getProperty("os.arch");
|
||||
if (arch.equals("x86_64") || arch.equals("amd64")) {
|
||||
executables {
|
||||
doxygen {
|
||||
executableByVersion('1.12.0')
|
||||
String arch = System.getProperty("os.arch");
|
||||
if (!(arch.equals("x86_64") || arch.equals("amd64"))) {
|
||||
// Search for a local doxygen install
|
||||
executableBySearchPath('doxygen')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user