]> source.dussan.org Git - gitea.git/commit
Fix build errors on BSD (in BSDMakefile) (#27594)
authorSergey Zolotarev <sryze@protonmail.com>
Fri, 13 Oct 2023 15:38:27 +0000 (21:38 +0600)
committerGitHub <noreply@github.com>
Fri, 13 Oct 2023 15:38:27 +0000 (15:38 +0000)
commitcf74f5fc40692f20508be9398675e38be41588d4
treede53a374ebe7ad33cb8edfa48fde844d9842ac8b
parent532f166c4dc7087a98e86aa1de5b697e6b5c6e4f
Fix build errors on BSD (in BSDMakefile) (#27594)

1. `make build` fails because `||` and `&&` have the same precedence in
sh/bash, so the `false` command always evaluated (leading to an error).

   ```
   + which gmake /usr/local/bin/gmake
   + false

   *** Failed target:  .BEGIN
*** Failed command: which "gmake" || printf "Error: GNU Make is
required!\n\n" 1>&2 && false
   *** Error code 1
   ```

2. When `GPREFIX` is set to an empty string with quotation marks,
`gmake` mistakenly thinks that it's a file name:

   ``` gmake: *** empty string invalid as file name.  Stop. ```
BSDmakefile