build: move raw rule into Makefile.am
The same rule is used by the tests and benchmarks to generate headers, and currently causes #25501. Just deduplicate the code into Makefile.am.
This commit is contained in:
3 files changed
+9
-18
No files matched your search
@@ -1065,6 +1065,15 @@ nodist_libbitcoin_ipc_a_SOURCES = $(libbitcoin_ipc_mpgen_output)
|
|||||||
CLEANFILES += $(libbitcoin_ipc_mpgen_output)
|
CLEANFILES += $(libbitcoin_ipc_mpgen_output)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
%.raw.h: %.raw
|
||||||
|
@$(MKDIR_P) $(@D)
|
||||||
|
@{ \
|
||||||
|
echo "static unsigned const char $(*F)_raw[] = {" && \
|
||||||
|
$(HEXDUMP) -v -e '8/1 "0x%02x, "' -e '"\n"' $< | $(SED) -e 's/0x ,//g' && \
|
||||||
|
echo "};"; \
|
||||||
|
} > "$@.new" && mv -f "$@.new" "$@"
|
||||||
|
@echo "Generated $@"
|
||||||
|
|
||||||
include Makefile.minisketch.include
|
include Makefile.minisketch.include
|
||||||
|
|
||||||
include Makefile.crc32c.include
|
include Makefile.crc32c.include
|
||||||
|
|||||||
@@ -93,12 +93,3 @@ bench: $(BENCH_BINARY) FORCE
|
|||||||
|
|
||||||
bitcoin_bench_clean : FORCE
|
bitcoin_bench_clean : FORCE
|
||||||
rm -f $(CLEAN_BITCOIN_BENCH) $(bench_bench_bitcoin_OBJECTS) $(BENCH_BINARY)
|
rm -f $(CLEAN_BITCOIN_BENCH) $(bench_bench_bitcoin_OBJECTS) $(BENCH_BINARY)
|
||||||
|
|
||||||
%.raw.h: %.raw
|
|
||||||
@$(MKDIR_P) $(@D)
|
|
||||||
@{ \
|
|
||||||
echo "static unsigned const char $(*F)_raw[] = {" && \
|
|
||||||
$(HEXDUMP) -v -e '8/1 "0x%02x, "' -e '"\n"' $< | $(SED) -e 's/0x ,//g' && \
|
|
||||||
echo "};"; \
|
|
||||||
} > "$@.new" && mv -f "$@.new" "$@"
|
|
||||||
@echo "Generated $@"
|
|
||||||
@@ -415,12 +415,3 @@ endif
|
|||||||
echo "};};"; \
|
echo "};};"; \
|
||||||
} > "$@.new" && mv -f "$@.new" "$@"
|
} > "$@.new" && mv -f "$@.new" "$@"
|
||||||
@echo "Generated $@"
|
@echo "Generated $@"
|
||||||
|
|
||||||
%.raw.h: %.raw
|
|
||||||
@$(MKDIR_P) $(@D)
|
|
||||||
@{ \
|
|
||||||
echo "static unsigned const char $(*F)_raw[] = {" && \
|
|
||||||
$(HEXDUMP) -v -e '8/1 "0x%02x, "' -e '"\n"' $< | $(SED) -e 's/0x ,//g' && \
|
|
||||||
echo "};"; \
|
|
||||||
} > "$@.new" && mv -f "$@.new" "$@"
|
|
||||||
@echo "Generated $@"
|
|
||||||
Reference in new issue
Block a user