Skip to content

fix: give a generated makefile the flags that were asked for - #346

Merged
jdhughes-dev merged 1 commit into
developfrom
fix-makefile-cflags-syslibs
Aug 19, 2026
Merged

fix: give a generated makefile the flags that were asked for#346
jdhughes-dev merged 1 commit into
developfrom
fix-makefile-cflags-syslibs

Conversation

@jdhughes-dev

Copy link
Copy Markdown
Collaborator

The fortran flags, c flags and linker flags a user asked for were all dropped from a generated makefile:

  • _get_fortran_flags and _get_linker_flags were called with an empty list, so --fflags and --syslibs never reached FFLAGS or LDFLAGS.
  • _get_c_flags was called with the fortran flags, so a fortran flag was written to CFLAGS and a c flag was written nowhere.
  • syslibs was a documented parameter of _create_makefile that the body never used, so it could not reach _write_makedefaults.

Each builder is now given the flags that belong to it, and syslibs is passed down. A makefile generated without any flags is byte identical to before.

The fortran flags, c flags and linker flags a user asked for were dropped
from a generated makefile. The fortran and linker flag builders were
called with an empty list, and the c flag builder was called with the
fortran flags, so a fortran flag was written to CFLAGS and a c flag was
written nowhere. The syslibs _create_makefile takes were never passed to
_write_makedefaults at all.

Each builder is now given the flags that belong to it, and syslibs is
passed down.
@codecov

codecov Bot commented Aug 19, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.972%. Comparing base (36d9ea1) to head (14f8c94).

Additional details and impacted files
@@              Coverage Diff              @@
##           develop      #346       +/-   ##
=============================================
+ Coverage   77.821%   80.972%   +3.150%     
=============================================
  Files           20        20               
  Lines         3269      3269               
=============================================
+ Hits          2544      2647      +103     
+ Misses         725       622      -103     
Files with missing lines Coverage Δ
pymake/pymake_base.py 90.125% <ø> (+0.718%) ⬆️

... and 6 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@jdhughes-dev
jdhughes-dev merged commit 325919c into develop Aug 19, 2026
23 checks passed
@jdhughes-dev
jdhughes-dev deleted the fix-makefile-cflags-syslibs branch August 19, 2026 18:38
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.

1 participant