diff mbox series

[1/3] tools/ocaml: Drop OCAMLOPTFLAG_G invocation

Message ID 20240823105157.991275-2-andrew.cooper3@citrix.com (mailing list archive)
State New
Headers show
Series tools/ocaml: Incremental build fixes | expand

Commit Message

Andrew Cooper Aug. 23, 2024, 10:51 a.m. UTC
These days, `ocamlopt -h` asks you whether you meant --help instead, meaning
that the $(shell ) invocation here isn't going end up containing '-g'.

Make it unconditional, like it is in OCAMLCFLAGS already.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
---
CC: Christian Lindig <christian.lindig@citrix.com>
CC: David Scott <dave@recoil.org>
CC: Edwin Török <edwin.torok@cloud.com>
CC: Rob Hoes <Rob.Hoes@citrix.com>
CC: Andrii Sultanov <andrii.sultanov@cloud.com>
CC: Anthony PERARD <anthony.perard@vates.tech>
---
 tools/ocaml/common.make | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/tools/ocaml/common.make b/tools/ocaml/common.make
index cc126b749f56..708d74617c8d 100644
--- a/tools/ocaml/common.make
+++ b/tools/ocaml/common.make
@@ -11,8 +11,7 @@  OCAMLFIND ?= ocamlfind
 
 CFLAGS += -fPIC -I$(shell ocamlc -where)
 
-OCAMLOPTFLAG_G := $(shell $(OCAMLOPT) -h 2>&1 | sed -n 's/^  *\(-g\) .*/\1/p')
-OCAMLOPTFLAGS = $(OCAMLOPTFLAG_G) -ccopt "$(LDFLAGS)" -dtypes $(OCAMLINCLUDE) -w F -warn-error F
+OCAMLOPTFLAGS = -g -ccopt "$(LDFLAGS)" -dtypes $(OCAMLINCLUDE) -w F -warn-error F
 OCAMLCFLAGS += -g $(OCAMLINCLUDE) -w F -warn-error F
 
 VERSION := 4.1