This thread contains a patchset. You're looking at the original emails,
but you may wish to use the patch review UI.
Review patch
2
2
[PATCH] Makefile: ensure POSIX 202X compliance
The current makefile isn't compliant with POSIX 2017.
Specifically, `pdpmake` warns about:
- The presence of '/' in target names
- The usage of '#' within commands
According to the pdpmake [homepage], the next POSIX
standard will address the first issue.
[homepage]: https://frippery.org/make/
---
Makefile | 10 +++++ -----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/Makefile b/Makefile
index 2482eb1..13769be 100644
--- a/Makefile
+++ b/Makefile
@@ -33,23 +33,23 @@ config.h:
*Darwin*) \
case `uname -m` in \
*arm64*) \
- echo "#define Deftgt T_arm64_apple";\
+ printf '%b%s\n' '\043' 'define Deftgt T_arm64_apple' \
;; \
*) \
- echo "#define Deftgt T_amd64_apple";\
+ printf '%b%s\n' '\043' 'define Deftgt T_amd64_apple' \
;; \
esac \
;; \
*) \
case `uname -m` in \
*aarch64*|*arm64*) \
- echo "#define Deftgt T_arm64"; \
+ printf '%b%s\n' '\043' 'define Deftgt T_arm64' \
;; \
*riscv64*) \
- echo "#define Deftgt T_rv64"; \
+ printf '%b%s\n' '\043' 'define Deftgt T_rv64' \
;; \
*) \
- echo "#define Deftgt T_amd64_sysv";\
+ printf '%b%s\n' '\043' 'define Deftgt T_amd64_sysv' \
;; \
esac \
;; \
--
2.45.2
Thanks for your patch but if pdpmake merely
warns I'll stick to the more readable
version of the Makefile.
Yeah, pdpmake is fully capable of generating qbe without any issues.
Although not ideal, that was the patch that I came up with.
If someone, in the future, can find a cleaner and simpler solution,
I am all for it.