Repository navigation
feat: define the version macros in fpc_status.h - #16
Merged
Merged
Conversation
fpc_version.h was generated at configure time, so a copied-in header had no version. fpc_status.h now defines the macros, including a long FPC_VERSION_NUMBER that cannot overflow a 16-bit int, and meson setup fails when they differ from project(version:). fpc_version.h stays installed as a deprecated header that includes fpc_status.h. The version block carries an inline Rule 2.5 deviation, because the library defines the macros for consumers and never uses them. Refs #15
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
fpc_status.hdefinesFPC_VERSIONand a newFPC_VERSION_NUMBER(long,MAJOR * 10000 + MINOR * 100 + PATCH), so a copy-in build carries its version.meson.buildreads the header withfs.readand fails to configure when any macro differs fromproject(version:);meson_versionis now>=0.57.0. The generated template is removed.fpc_version.his a deprecated header that includesfpc_status.h, installed beside it until the next major release.fpc_status.h, whichfpc_pid.handfpc_filters.hboth include.fpc_version.his installed as a deprecated header that includes it.incdrops the'.'directory, which only served the generated header.tests/test_filters.cgains aversion_macroscase that includesfpc_version.hand checksFPC_VERSION_NUMBERagainst its parts.docs/design.md; the baseline is unchanged.docs/api.mdgains a Version section with a compiled#ifexample; integration, AGENTS and CHANGELOG are updated.Checks run
meson testunder ASan and UBSan: unit tests (27 subtests, includingversion_macros) and the docs examples pass.FPC_VERSION_MINORset to 4 fails configure withinclude/fpc_status.h must define FPC_VERSION_MINOR as 3.misch run --baselineandmisch deviations: clean.scripts/format.sh: clean.fpc_version.hand checking every macro compiles with gcc and g++-Werrorand with cl2000 22.6.2 and 25.11.1--c11under COFF and EABI with--emit_warnings_as_errors.Refs #15