Skip to content

Makefile.config: restore the {OCAMLC,OCAMLOPT}_{CFLAGS,CPPFLAGS} variables#13519

Merged
dra27 merged 1 commit intoocaml:trunkfrom
shindere:cflags-variables-backward-compatibility
Nov 6, 2024
Merged

Makefile.config: restore the {OCAMLC,OCAMLOPT}_{CFLAGS,CPPFLAGS} variables#13519
dra27 merged 1 commit intoocaml:trunkfrom
shindere:cflags-variables-backward-compatibility

Conversation

@shindere
Copy link
Copy Markdown
Contributor

@shindere shindere commented Oct 3, 2024

They had been renamed in 31cdf41
(part of #12589) but we should keep the old names for backward compatibility.

This is thus a proposed fix for the issue #13503 and should probably go
through @dra27.

Copy link
Copy Markdown

@ghost ghost left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good. Maybe add a future deprecation comment somewhere?

@shindere shindere force-pushed the cflags-variables-backward-compatibility branch 2 times, most recently from 2f298b6 to 609faea Compare October 7, 2024 15:11
@shindere
Copy link
Copy Markdown
Contributor Author

shindere commented Oct 7, 2024 via email

@dra27 dra27 linked an issue Oct 16, 2024 that may be closed by this pull request
@dra27 dra27 added this to the 5.3.0 milestone Oct 21, 2024
Comment thread Makefile.config.in Outdated
Comment on lines +226 to +229
OCAMLC_CFLAGS=$(BYTECODE_CFLAGS)
OCAMLOPT_CFLAGS=$(OCAMLOPT_CFLAGS)
OCAMLC_CPPFLAGS=$(BYTECODE_CPPFLAGS)
OCAMLOPT_CPPFLAGS=@native_cppflags@
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems OK to have OCAMLC_CFLAGS and OCAMLC_CPPFLAGS being renamed, and OCAMLOPT_CFLAGS and OCAMLOPT_CPPFLAGS removed. There's a small typo with it:

Suggested change
OCAMLC_CFLAGS=$(BYTECODE_CFLAGS)
OCAMLOPT_CFLAGS=$(OCAMLOPT_CFLAGS)
OCAMLC_CPPFLAGS=$(BYTECODE_CPPFLAGS)
OCAMLOPT_CPPFLAGS=@native_cppflags@
OCAMLC_CFLAGS=$(BYTECODE_CFLAGS)
OCAMLOPT_CFLAGS=@native_cflags@
OCAMLC_CPPFLAGS=$(BYTECODE_CPPFLAGS)
OCAMLOPT_CPPFLAGS=@native_cppflags@

(I equally don't mind if you just go with the first commit)

@shindere shindere changed the title Makefile.config: restore the {OCAMLC,OCAMLOPT}_{CFLAGS,CPPFLAGS} nvariables Makefile.config: restore the {OCAMLC,OCAMLOPT}_{CFLAGS,CPPFLAGS} variables Nov 5, 2024
…ables

They had been renamed in 31cdf41
(part of ocaml#12589) but we should keep the old names for backward compatibility.
@shindere shindere force-pushed the cflags-variables-backward-compatibility branch from 609faea to 59f4d28 Compare November 5, 2024 15:10
@shindere
Copy link
Copy Markdown
Contributor Author

shindere commented Nov 5, 2024 via email

Copy link
Copy Markdown
Member

@dra27 dra27 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let’s do it!

@dra27 dra27 merged commit f2bac84 into ocaml:trunk Nov 6, 2024
dra27 added a commit that referenced this pull request Nov 6, 2024
…patibility

Makefile.config: restore the {OCAMLC,OCAMLOPT}_{CFLAGS,CPPFLAGS} variables

(cherry picked from commit f2bac84)
@shindere
Copy link
Copy Markdown
Contributor Author

shindere commented Nov 7, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[5.3] Was the renaming of OCAMLC_CFLAGS in Makefile.config intended?

2 participants