aboutsummaryrefslogtreecommitdiff
path: root/auxiliary
diff options
context:
space:
mode:
authorSimon Tatham <anakin@pobox.com>2023-06-15 07:40:14 +0100
committerSimon Tatham <anakin@pobox.com>2023-06-16 18:32:55 +0100
commitde13ca2874e673b426efcf04f734ae6625635396 (patch)
treeb1db4f29b83a3a545ec60448fc5096b87243f475 /auxiliary
parent43f4fde2f2ef694f355edc2777525cf611dc0182 (diff)
downloadpuzzles-de13ca2874e673b426efcf04f734ae6625635396.zip
puzzles-de13ca2874e673b426efcf04f734ae6625635396.tar.gz
puzzles-de13ca2874e673b426efcf04f734ae6625635396.tar.bz2
puzzles-de13ca2874e673b426efcf04f734ae6625635396.tar.xz
Add a 'core' library alongside 'common'.
The 'core' library contains almost all the same objects as 'common', but leaves out hat.c. And the auxiliary program 'hatgen' now links against that slightly reduced core library instead of 'common'. This avoids a dependency loop: one of hatgen's jobs is to generate hat-tables.h, but hat-tables.h is a dependency of it. Of course, the generated hat-tables.h is already committed, so this doesn't present a bootstrapping problem in a normal build. But if someone modifies hatgen.c in order to regenerate hat-tables.h, and does so in a way that makes it uncompilable, they can't rebuild hatgen and try again! Of course you can always revert changes with git, but it's annoying to have to. Better to keep the dependencies non-cyclic in the first place.
Diffstat (limited to 'auxiliary')
-rw-r--r--auxiliary/CMakeLists.txt2
1 files changed, 1 insertions, 1 deletions
diff --git a/auxiliary/CMakeLists.txt b/auxiliary/CMakeLists.txt
index f475812..b9c1067 100644
--- a/auxiliary/CMakeLists.txt
+++ b/auxiliary/CMakeLists.txt
@@ -1,6 +1,6 @@
cliprogram(combi-test combi-test.c)
cliprogram(divvy-test divvy-test.c)
-cliprogram(hatgen hatgen.c COMPILE_DEFINITIONS TEST_HAT)
+cliprogram(hatgen hatgen.c CORE_LIB COMPILE_DEFINITIONS TEST_HAT)
cliprogram(hat-test hat-test.c)
cliprogram(latin-test latin-test.c)
cliprogram(matching matching.c)