commit 53ee1e571244f465783a084ab25b3846f545bb17
parent ec95bc802761cf9f17089c20299a521e9e7c0525
Author: Sebastian <sebastian@sebsite.pw>
Date: Sat, 9 Dec 2023 21:16:56 -0500
hare build: fix order of flags
-F doesn't take in a parameter, so it should be sorted before everything
that does.
Signed-off-by: Sebastian <sebastian@sebsite.pw>
Diffstat:
2 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/cmd/hare/main.ha b/cmd/hare/main.ha
@@ -22,13 +22,13 @@ const help: []getopt::help = [
"args...",
("build", [
"compiles a Hare program or module",
+ // XXX: once cross-compiling to different targets (linux,
+ // freebsd, etc) is supported, we can probably merge -F with it
+ ('F', "build for freestanding environment"),
('q', "build silently"),
('v', "print executed commands (specify twice to print arguments)"),
('a', "arch", "set target architecture"),
('D', "ident[:type]=value", "define a constant"),
- // XXX: once cross-compiling to different targets (linux,
- // freebsd, etc) is supported, we can probably merge -F with it
- ('F', "build for freestanding environment"),
('j', "jobs", "set parallelism for build"),
('L', "libdir", "add directory to linker library search path"),
('l', "libname", "link with a system library"),
diff --git a/docs/hare-build.1.scd b/docs/hare-build.1.scd
@@ -6,10 +6,9 @@ hare build - compile a Hare program or module
# SYNOPSIS
-*hare build* [-hqv]++
+*hare build* [-hFqv]++
[-a _arch_]++
[-D _ident[:type]=value_]++
- [-F]++
[-j _jobs_]++
[-L _libdir_]++
[-l _libname_]++
@@ -32,6 +31,10 @@ working directory is built.
*-h*
Print the help text.
+*-F*
+ Build for freestanding (non-hosted) environment. This allows a
+ declaration whose symbol is main to take on any form.
+
*-q*
Outside of errors, don't write anything to stdout while building.
@@ -49,10 +52,6 @@ working directory is built.
"42"). Take care to address any necessary escaping to avoid conflicts
between your shell syntax and Hare syntax.
-*-F*
- Build for freestanding (non-hosted) environment. This allows a
- declaration whose symbol is main to take on any form.
-
*-j* _jobs_
Set the maximum number of jobs to execute in parallel. The default is
the number of processors available on the host.