api7 / api7/lua-resty-saml

Makefile: single-run archive bootstrap and honest dependencies

Open
#59 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Perl
Stars
2
Forks
3
Avg merge
2d 20h
Merged PRs (30d)
3

Description

Follow-ups from the build-graph review on #53, kept out of that PR since all of them predate it.

  • $(XMLSEC1_STATIC_LIBS): lists two targets on one rule, so make expands it into two independent rules sharing the wget/tar/configure recipe: make -B build runs the bootstrap twice. A grouped target (&:, GNU Make >= 4.3) or a stamp file both archives depend on fixes the double run; the stamp is the portable choice (macOS ships make 3.81).
  • With the double run fixed, saml.so can again list the archives as prerequisites, so a rebuilt xmlsec relinks instead of shipping stale whole-archived objects.
  • Object files rebuild on any src/*.h change via a blanket prerequisite; compiler-generated dependencies (-MMD) would narrow that honestly.
  • Variables (OPENSSL_DIR, CFLAGS) trigger no rebuild; a flags stamp would. Related: the default OPENSSL_DIR ?= /usr/local/openresty/openssl111 targets the older runtime line, and gcc silently ignores the missing include/lib dirs when it is absent, linking the system OpenSSL.
  • Pre-existing and observed on the merge-base of #53: make -j4 race on a clean tree, and make saml.so on a clean tree failing at lua_saml.o before the archives exist.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Makefile and reproduce the reported clean-tree failures using make -j4 and make saml.so. Trace the archive, saml.so, object, and OpenSSL-related prerequisites; done means bootstrap runs once, parallel builds are reliable, rebuilt archives relink, and header or flag changes trigger the intended rebuilds.

Written by the indexing model from the issue text.

Assessment

Tech stack
lua
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.