Re: [PATCH 1/6] lib: Add missing config.h include to next_prime.c
Hi Mark, On Monday, October 14th, 2024 at 16:38, Mark Wielaard wrote: > > > There isn't much code in this file. What kind of build issue are you > seeing without this? Does config.h contain some construct that affects > the build of this file? Like I mentioned in the cover letter, we incorporate gnulib to the build, so the build simply fails due to their strict requirements of including config.h before including any other header that gnulib provides. I'm not familiar with the exact reason for this requirement, but I'm sure it could potentially cause a problem if one overrides it. -- MCP
Re: [PATCH 6/6] Use file stream or format variants of stdio print functions
Hi again, On Monday, October 14th, 2024 at 17:30, Mark Wielaard wrote: > > > If we are trying to be more consistent then I think I would prefer we > use putchar, puts, and printf, instead of adding stdout to all these > calls. I don't really have a preference, you could even throw out this last patch. I just thought it would be nice to remove use of one of the functions from the whole project to reduce needless variations and save the need to link more functions that do the exact same thing and waste binary space. Also, that searching "puts" results in "outputs" and "inputs"... It would be nice to have patch 5 before release, for patch 6 doesn't matter if or when to me. Let me know if you want a v2 of either patch 5 or 6. -- MCP
[PATCH v2 5/6] Remove usage of "unlocked" variant of stdio print functions
These "unlocked" Linux Standard Base variants of standard functions are not available on some systems that are still capable of building Linux and ELFs. The difference is negligible for simple printing to stdout. POSIX also states for the similar putc_unlocked(): These functions can safely be used in a multi-threaded program if and only if they are called while the invoking thread owns the (FILE *) object, as is the case after a successful call to the flockfile() or ftrylockfile() functions. ... These unlocked versions can be safely used only within explicitly locked program regions, using exported locking primitives. and these precautions were never done. Use the standard forms of these print functions. There is inconsistent use of fputc_unlocked() with putc_unlocked(), so consistently use the safer fputc() instead. Signed-off-by: Michael Pratt --- libasm/asm_align.c | 4 +- libcpu/i386_parse.y | 4 +- libebl/eblobjnote.c | 4 +- src/nm.c| 20 +- src/objdump.c | 24 ++-- src/readelf.c | 90 ++--- src/size.c | 8 ++-- src/strings.c | 20 +- tests/showptable.c | 8 ++-- 9 files changed, 91 insertions(+), 91 deletions(-) diff --git a/libasm/asm_align.c b/libasm/asm_align.c index 3a976756..19ec9a13 100644 --- a/libasm/asm_align.c +++ b/libasm/asm_align.c @@ -60,13 +60,13 @@ asm_align (AsmScn_t *asmscn, GElf_Word value) fprintf (asmscn->ctx->out.file, "%02hhx\n", asmscn->pattern->bytes[0]); else { - fputc_unlocked ('"', asmscn->ctx->out.file); + fputc ('"', asmscn->ctx->out.file); for (size_t cnt = 0; cnt < asmscn->pattern->len; ++cnt) fprintf (asmscn->ctx->out.file, "\\x%02hhx", asmscn->pattern->bytes[cnt]); - fputs_unlocked ("\"\n", asmscn->ctx->out.file); + fputs ("\"\n", asmscn->ctx->out.file); } return 0; } diff --git a/libcpu/i386_parse.y b/libcpu/i386_parse.y index 459684c6..5c91e520 100644 --- a/libcpu/i386_parse.y +++ b/libcpu/i386_parse.y @@ -1158,7 +1158,7 @@ instrtable_out (void) EMIT_SUFFIX (w1); EMIT_SUFFIX (W1); - fputc_unlocked ('\n', outfile); + fputc ('\n', outfile); for (int i = 0; i < 3; ++i) { @@ -1333,7 +1333,7 @@ instrtable_out (void) b = b->next; } - fputc_unlocked ('\n', outfile); + fputc ('\n', outfile); } fputs ("};\n", outfile); } diff --git a/libebl/eblobjnote.c b/libebl/eblobjnote.c index ad3f49de..da69e99c 100644 --- a/libebl/eblobjnote.c +++ b/libebl/eblobjnote.c @@ -648,10 +648,10 @@ ebl_object_note (Ebl *ebl, uint32_t namesz, const char *name, uint32_t type, for (size_t cnt = 1; cnt < descsz / 4; ++cnt) { if (cnt > 1) - putchar_unlocked ('.'); + putchar ('.'); printf ("%" PRIu32, buf[cnt]); } - putchar_unlocked ('\n'); + putchar ('\n'); } if (descsz / 4 > FIXED_TAG_BYTES) free (buf); diff --git a/src/nm.c b/src/nm.c index 3675f59b..06f1a072 100644 --- a/src/nm.c +++ b/src/nm.c @@ -439,7 +439,7 @@ handle_ar (int fd, Elf *elf, const char *prefix, const char *fname, Elf_Arhdr *arhdr = NULL; size_t arhdr_off = 0; /* Note: 0 is no valid offset. */ - fputs_unlocked (_("\nArchive index:\n"), stdout); + fputs (_("\nArchive index:\n"), stdout); while (arsym->as_off != 0) { @@ -825,8 +825,8 @@ show_symbols_sysv (Ebl *ebl, GElf_Word strndx, const char *fullname, /* If we have to precede the line with the file name. */ if (print_file_name) { - fputs_unlocked (fullname, stdout); - putchar_unlocked (':'); + fputs (fullname, stdout); + putchar (':'); } /* Convert the address. */ @@ -972,8 +972,8 @@ show_symbols_bsd (Elf *elf, const GElf_Ehdr *ehdr, GElf_Word strndx, /* If we have to precede the line with the file name. */ if (print_file_name) { - fputs_unlocked (fullname, stdout); - putchar_unlocked (':'); + fputs (fullname, stdout); + putchar (':'); } bool is_tls = GELF_ST_TYPE (syms[cnt].sym.st_info) == STT_TLS; @@ -1046,8 +1046,8 @@ show_symbols_bsd (Elf *elf, const GElf_Ehdr *ehdr, GElf_Word strndx, } if (color_mode) - fputs_unlocked (color_off, stdout); - putchar_unlocked ('\n&
[PATCH 0/6] Various portability fixes and organization
Hi, I saw that elfutils is having a release soon, so I thought now would be a good time to send some patches that are used by the Openwrt project to help elfutils build on more systems, for example, by integrating with gnulib/libtool, and coinciding with custom patches applied to other build tools. The first 4 patches are very simple so I'm hoping they can be merged ASAP. The last 2 patches are less critical, especially the last one which is just an organizational step. If the last 2 patches are not acceptable, they can be dropped or revisited after the release. Thanks, MCP Michael Pratt (6): lib: Add missing config.h include to next_prime.c libcpu: Include config.h before standard headers in lexer source libdw: Let clean targets be unconditional src: Prevent invalid include of binary into compilation Remove usage of "unlocked" variant of stdio print functions Use file stream or format variants of stdio print functions lib/next_prime.c | 4 + libasm/asm_align.c| 4 +- libcpu/i386_disasm.c | 2 +- libcpu/i386_lex.l | 10 +- libcpu/i386_parse.y | 4 +- libdw/Makefile.am | 2 +- libebl/eblobjnote.c | 4 +- src/Makefile.am | 1 + src/addr2line.c | 8 +- src/ar.c | 2 +- src/elfclassify.c | 2 +- src/elflint.c | 2 +- src/nm.c | 22 ++-- src/objdump.c | 28 ++--- src/readelf.c | 198 +- src/size.c| 8 +- src/strings.c | 20 ++-- src/unstrip.c | 2 +- tests/addrcfi.c | 2 +- tests/addrscopes.c| 2 +- tests/all-dwarf-ranges.c | 4 +- tests/arextract.c | 4 +- tests/asm-tst1.c | 6 +- tests/asm-tst2.c | 6 +- tests/asm-tst3.c | 8 +- tests/asm-tst4.c | 2 +- tests/asm-tst5.c | 2 +- tests/asm-tst6.c | 2 +- tests/asm-tst7.c | 6 +- tests/asm-tst8.c | 6 +- tests/asm-tst9.c | 6 +- tests/buildid.c | 4 +- tests/debugaltlink.c | 4 +- tests/dwarf-getmacros.c | 6 +- tests/dwarf-getstring.c | 2 +- tests/dwarf-ranges.c | 2 +- tests/dwarfcfi.c | 2 +- tests/dwflmodtest.c | 6 +- tests/funcretval.c| 6 +- tests/funcscopes.c| 2 +- tests/get-aranges.c | 6 +- tests/get-files-define-file.c | 2 +- tests/get-files.c | 2 +- tests/get-pubnames.c | 4 +- tests/line2addr.c | 4 +- tests/next-files.c| 2 +- tests/saridx.c| 2 +- tests/scnnames.c | 2 +- tests/sectiondump.c | 4 +- tests/show-die-info.c | 62 +-- tests/showptable.c| 10 +- tests/test-nlist.c| 2 +- 52 files changed, 262 insertions(+), 253 deletions(-) -- 2.30.2
[PATCH 2/6] libcpu: Include config.h before standard headers in lexer source
As part of the processing of flex, definitions and headers are added to output source before any literal text or generated code. This causes standard headers to come before config.h unless config.h is included in a %top block instead as specified in the flex manual, section 5.1 "Format of the Definitions". The %top block is non-POSIX, so using it reinforces the requirement of "flex" over a standardized "lex" even more. * libcpu/i386_lex.l (%top): add flex %top block and move config.h header inclusion to it. Signed-off-by: Michael Pratt --- libcpu/i386_lex.l | 10 ++ 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/libcpu/i386_lex.l b/libcpu/i386_lex.l index 9b33ed95..9c1e14db 100644 --- a/libcpu/i386_lex.l +++ b/libcpu/i386_lex.l @@ -1,3 +1,9 @@ +%top{ +#ifdef HAVE_CONFIG_H +# include +#endif +} + %{ /* Copyright (C) 2004, 2005, 2007, 2008 Red Hat, Inc. Written by Ulrich Drepper , 2004. @@ -26,10 +32,6 @@ the GNU Lesser General Public License along with this program. If not, see <http://www.gnu.org/licenses/>. */ -#ifdef HAVE_CONFIG_H -# include -#endif - #include #include -- 2.30.2
[PATCH 5/6] Remove usage of "unlocked" variant of stdio print functions
These Linux Standard Base functions are not available on all systems that are capable of building Linux and ELFs. The difference is negligible for simple printing to stdout. POSIX also states for the similar putc_unlocked(): These functions can safely be used in a multi-threaded program if and only if they are called while the invoking thread owns the (FILE *) object, as is the case after a successful call to the flockfile() or ftrylockfile() functions. and These unlocked versions can be safely used only within explicitly locked program regions, using exported locking primitives. and this was never done. There is inconsistent use of fputc_unlocked() mixed with putc_unlocked() and putchar_unlocked(), so consistently use the safer fputc() instead. Signed-off-by: Michael Pratt --- libasm/asm_align.c | 4 +- libcpu/i386_parse.y | 4 +- libebl/eblobjnote.c | 4 +- src/nm.c| 20 +- src/objdump.c | 24 ++-- src/readelf.c | 90 ++--- src/size.c | 8 ++-- src/strings.c | 20 +- tests/showptable.c | 8 ++-- 9 files changed, 91 insertions(+), 91 deletions(-) diff --git a/libasm/asm_align.c b/libasm/asm_align.c index 3a976756..19ec9a13 100644 --- a/libasm/asm_align.c +++ b/libasm/asm_align.c @@ -60,13 +60,13 @@ asm_align (AsmScn_t *asmscn, GElf_Word value) fprintf (asmscn->ctx->out.file, "%02hhx\n", asmscn->pattern->bytes[0]); else { - fputc_unlocked ('"', asmscn->ctx->out.file); + fputc ('"', asmscn->ctx->out.file); for (size_t cnt = 0; cnt < asmscn->pattern->len; ++cnt) fprintf (asmscn->ctx->out.file, "\\x%02hhx", asmscn->pattern->bytes[cnt]); - fputs_unlocked ("\"\n", asmscn->ctx->out.file); + fputs ("\"\n", asmscn->ctx->out.file); } return 0; } diff --git a/libcpu/i386_parse.y b/libcpu/i386_parse.y index 459684c6..5c91e520 100644 --- a/libcpu/i386_parse.y +++ b/libcpu/i386_parse.y @@ -1158,7 +1158,7 @@ instrtable_out (void) EMIT_SUFFIX (w1); EMIT_SUFFIX (W1); - fputc_unlocked ('\n', outfile); + fputc ('\n', outfile); for (int i = 0; i < 3; ++i) { @@ -1333,7 +1333,7 @@ instrtable_out (void) b = b->next; } - fputc_unlocked ('\n', outfile); + fputc ('\n', outfile); } fputs ("};\n", outfile); } diff --git a/libebl/eblobjnote.c b/libebl/eblobjnote.c index ad3f49de..da69e99c 100644 --- a/libebl/eblobjnote.c +++ b/libebl/eblobjnote.c @@ -648,10 +648,10 @@ ebl_object_note (Ebl *ebl, uint32_t namesz, const char *name, uint32_t type, for (size_t cnt = 1; cnt < descsz / 4; ++cnt) { if (cnt > 1) - putchar_unlocked ('.'); + fputc ('.', stdout); printf ("%" PRIu32, buf[cnt]); } - putchar_unlocked ('\n'); + fputc ('\n', stdout); } if (descsz / 4 > FIXED_TAG_BYTES) free (buf); diff --git a/src/nm.c b/src/nm.c index 3675f59b..06f1a072 100644 --- a/src/nm.c +++ b/src/nm.c @@ -439,7 +439,7 @@ handle_ar (int fd, Elf *elf, const char *prefix, const char *fname, Elf_Arhdr *arhdr = NULL; size_t arhdr_off = 0; /* Note: 0 is no valid offset. */ - fputs_unlocked (_("\nArchive index:\n"), stdout); + fputs (_("\nArchive index:\n"), stdout); while (arsym->as_off != 0) { @@ -825,8 +825,8 @@ show_symbols_sysv (Ebl *ebl, GElf_Word strndx, const char *fullname, /* If we have to precede the line with the file name. */ if (print_file_name) { - fputs_unlocked (fullname, stdout); - putchar_unlocked (':'); + fputs (fullname, stdout); + fputc (':', stdout); } /* Convert the address. */ @@ -972,8 +972,8 @@ show_symbols_bsd (Elf *elf, const GElf_Ehdr *ehdr, GElf_Word strndx, /* If we have to precede the line with the file name. */ if (print_file_name) { - fputs_unlocked (fullname, stdout); - putchar_unlocked (':'); + fputs (fullname, stdout); + fputc (':', stdout); } bool is_tls = GELF_ST_TYPE (syms[cnt].sym.st_info) == STT_TLS; @@ -1046,8 +1046,8 @@ show_symbols_bsd (Elf *elf, const GElf_Ehdr *ehdr, GElf_Word strndx, } if (color_mode) - fputs_unlocked (color_off, stdout); - putchar_unlocked ('\n'); + fputs (color_off, stdout); +
[PATCH 3/6] libdw: Let clean targets be unconditional
The automake rule "maintainer-clean-generic" is always available and never conditional, so let the variable that uses it be define non-conditionally. If one actually wants conditional cleaning they should write a custom rule and set it as a dependency of a "*clean-local" automake rule. There is no need to do conditional cleaning here, so move the MAINTAINERCLEANFILES variable definition to the end of the Makefile.am file as it is in the rest of the project. * libdw/Makefile.am: move MAINTAINERCLEANFILES variable to the end of the file as a non-conditional definition. Signed-off-by: Michael Pratt --- libdw/Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libdw/Makefile.am b/libdw/Makefile.am index 5363c02a..4b9c4413 100644 --- a/libdw/Makefile.am +++ b/libdw/Makefile.am @@ -97,7 +97,6 @@ libdw_a_SOURCES = dwarf_begin.c dwarf_begin_elf.c dwarf_end.c dwarf_getelf.c \ if MAINTAINER_MODE BUILT_SOURCES = $(srcdir)/known-dwarf.h -MAINTAINERCLEANFILES = $(srcdir)/known-dwarf.h $(srcdir)/known-dwarf.h: $(top_srcdir)/config/known-dwarf.awk $(srcdir)/dwarf.h gawk -f $^ > $@.new mv -f $@.new $@ @@ -154,3 +153,4 @@ noinst_HEADERS = libdwP.h memory-access.h dwarf_abbrev_hash.h \ EXTRA_DIST = libdw.map MOSTLYCLEANFILES = $(am_libdw_pic_a_OBJECTS) libdw.so libdw.so.$(VERSION) +MAINTAINERCLEANFILES = $(srcdir)/known-dwarf.h -- 2.30.2
[PATCH 4/6] src: Prevent invalid include of binary into compilation
The "stack" binary built by elfutils has the same name as the standard C++ header . If that header were to be in the list of includes while building the C++ elfutils program "srcfiles", then there is a chance that the "stack" binary is included instead and treated as text, leading to a decode error if "stack" happens to be built first and "." is in the include paths. Adding the result of C++ compilation srcfiles.o to the dependencies of "stack" ensures that the C++ compilation will happen first, before the stack binary is present. While this doesn't guarantee an error will not occur in all cases, it does guarantee that it will not occur from a clean build state. * src/Makefile.am: Add compilation dependency between the stack and srcfiles binaries. Signed-off-by: Michael Pratt --- src/Makefile.am | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Makefile.am b/src/Makefile.am index e0267d96..c5474c68 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -94,6 +94,7 @@ strings_LDADD = $(libelf) $(libeu) $(argp_LDADD) ar_LDADD = libar.a $(libelf) $(libeu) $(argp_LDADD) $(obstack_LIBS) unstrip_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) stack_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) $(demanglelib) +EXTRA_stack_DEPENDENCIES = $(if $(findstring srcfiles,$(bin_PROGRAMS)),$(srcfiles_OBJECTS)) elfcompress_LDADD = $(libebl) $(libelf) $(libdw) $(libeu) $(argp_LDADD) elfclassify_LDADD = $(libelf) $(libdw) $(libeu) $(argp_LDADD) srcfiles_SOURCES = srcfiles.cxx -- 2.30.2
[PATCH 1/6] lib: Add missing config.h include to next_prime.c
This is the last remaining C source file as of this commit without the standard conditional inclusion of config.h as the very first header. * lib/next_prime.c: add missing config.h header. Signed-off-by: Michael Pratt --- lib/next_prime.c | 4 1 file changed, 4 insertions(+) diff --git a/lib/next_prime.c b/lib/next_prime.c index f2c921e3..97c425e1 100644 --- a/lib/next_prime.c +++ b/lib/next_prime.c @@ -27,6 +27,10 @@ the GNU Lesser General Public License along with this program. If not, see <http://www.gnu.org/licenses/>. */ +#ifdef HAVE_CONFIG_H +# include +#endif + #include -- 2.30.2
[PATCH 6/6] Use file stream or format variants of stdio print functions
In many source files, putc() and fputc() and putchar() are used interchangeably, and puts() and fputs() and printf() are used interchangeably. Reducing the usage to 2 of the 3 both reduces binary size of the final product, improves readability and searchability of the code, especially since grepping for puts() can clash with words like "inputs" and "outputs", and that putc() can be a macro while fputc() is the safer function. While at it, adjust spacing syntax and punctuation for consistency. Signed-off-by: Michael Pratt --- libcpu/i386_disasm.c | 2 +- src/addr2line.c | 8 +-- src/ar.c | 2 +- src/elfclassify.c | 2 +- src/elflint.c | 2 +- src/nm.c | 2 +- src/objdump.c | 4 +- src/readelf.c | 108 +- src/unstrip.c | 2 +- tests/addrcfi.c | 2 +- tests/addrscopes.c| 2 +- tests/all-dwarf-ranges.c | 4 +- tests/arextract.c | 4 +- tests/asm-tst1.c | 6 +- tests/asm-tst2.c | 6 +- tests/asm-tst3.c | 8 +-- tests/asm-tst4.c | 2 +- tests/asm-tst5.c | 2 +- tests/asm-tst6.c | 2 +- tests/asm-tst7.c | 6 +- tests/asm-tst8.c | 6 +- tests/asm-tst9.c | 6 +- tests/buildid.c | 4 +- tests/debugaltlink.c | 4 +- tests/dwarf-getmacros.c | 6 +- tests/dwarf-getstring.c | 2 +- tests/dwarf-ranges.c | 2 +- tests/dwarfcfi.c | 2 +- tests/dwflmodtest.c | 6 +- tests/funcretval.c| 6 +- tests/funcscopes.c| 2 +- tests/get-aranges.c | 6 +- tests/get-files-define-file.c | 2 +- tests/get-files.c | 2 +- tests/get-pubnames.c | 4 +- tests/line2addr.c | 4 +- tests/next-files.c| 2 +- tests/saridx.c| 2 +- tests/scnnames.c | 2 +- tests/sectiondump.c | 4 +- tests/show-die-info.c | 62 +-- tests/showptable.c| 2 +- tests/test-nlist.c| 2 +- 43 files changed, 159 insertions(+), 157 deletions(-) diff --git a/libcpu/i386_disasm.c b/libcpu/i386_disasm.c index dec62bfa..7f199b49 100644 --- a/libcpu/i386_disasm.c +++ b/libcpu/i386_disasm.c @@ -565,7 +565,7 @@ i386_disasm (Ebl *ebl __attribute__((unused)), #endif default: /* Cannot happen. */ - puts ("unknown prefix"); + fputs ("unknown prefix\n", stdout); abort (); } data = begin + 1; diff --git a/src/addr2line.c b/src/addr2line.c index d87e5b45..9ced8a62 100644 --- a/src/addr2line.c +++ b/src/addr2line.c @@ -729,10 +729,10 @@ handle_address (const char *string, Dwfl *dwfl) show_int (&dwarf_lineisa, info, "isa"); show_int (&dwarf_linediscriminator, info, "discriminator"); } - putchar ('\n'); + fputc ('\n', stdout); } else -puts ("??:0"); +fputs ("??:0\n", stdout); if (show_inlines) { @@ -811,10 +811,10 @@ handle_address (const char *string, Dwfl *dwfl) if (src != NULL) { print_src (src, lineno, linecol, &cu); - putchar ('\n'); + fputc ('\n', stdout); } else - puts ("??:0"); + fputs ("??:0\n", stdout); } } } diff --git a/src/ar.c b/src/ar.c index 9ace28b9..ad48c395 100644 --- a/src/ar.c +++ b/src/ar.c @@ -579,7 +579,7 @@ do_oper_extract (int oper, const char *arfname, char **argv, int argc, if (oper == oper_list) { if (!verbose) - puts (arhdr->ar_name); + printf ("%s\n", arhdr->ar_name); goto next; } diff --git a/src/elfclassify.c b/src/elfclassify.c index 25fe9a65..8c18b5d1 100644 --- a/src/elfclassify.c +++ b/src/elfclassify.c @@ -820,7 +820,7 @@ process_current_path (int *status) { case do_print: if (checks_passed == flag_print_matching) -puts (current_path); +printf ("%s\n", current_path); break; case do_print0: if (checks_passed == flag_print_matching) diff --git a/src/elflint.c b/src/elflint.c index cdc6108d..24f3c043 100644 --- a/src/elflint.c +++ b/src/elflint.c @@ -181,7 +181,7 @@ main (int argc, char *argv[]) elf_errmsg (-1)); if (prev_error_count =
Re: [PATCH 6/6] Use file stream or format variants of stdio print functions
Hi Aaron, On 10/22/24 4:45 PM, Aaron Merey wrote: > Hi Michael, > > On Tue, Oct 15, 2024 at 11:10 AM Michael Pratt wrote: > > It would be nice to have patch 5 before release, > > for patch 6 doesn't matter if or when to me. > > > > Let me know if you want a v2 of either patch 5 or 6. > > I'm not able to apply this patch locally because it contains various > hex codes like '=20' instead of the corresponding ASCII character. Can > you recreate the patch file with 'git format-patch' and resend? I did use git commands to get it to the list. Honestly, lets just forget about the last patch, since Mark expressed a desire to just keep putchar() there isn't much of a point. I have other higher priority things to send anyway. -- MCP
[PATCH] Consolidate and add files to clean target variables
To increase the consistency of how automatic clean targets run, define the variables together without +=, default to MOSTLYCLEANFILES when there is no need for different levels or add more clean levels to match other subdirectories, add more files that are built, remove duplication, and cleanup. Do the same for EXTRA_DIST where it is equally messy. * backends/Makefile.am: add more objects to clean, improve spacing. * debuginfod/Makefile.am: Likewise, and remove duplicates. * lib/Makefile.am: improve spacing. * libasm/Makefile.am: add more objects to clean, split similar to debuginfod. * libcpu/Makefile.am: use normal =, add more objects to clean. * libdw/Makefile.am: add more objects to clean, split similar to debuginfod. * libdwelf/Makefile.am: add more objects to clean, use lowest clean level. * libdwfl/Makefile.am: Likewise. * libebl/Makefile.am: add more objects to clean. * libelf/Makefile.am: add more objects to clean, split similar to debuginfod. * src/Makefile.am: consolidate including EXTRA_DIST, split clean levels, define with normal =, define with variables. * tests/Makefile.am: Likewise, but not including EXTRA_DIST. Signed-off-by: Michael Pratt --- backends/Makefile.am | 3 ++- debuginfod/Makefile.am | 5 +++-- lib/Makefile.am| 1 + libasm/Makefile.am | 4 +++- libcpu/Makefile.am | 6 +++--- libdw/Makefile.am | 3 ++- libdwelf/Makefile.am | 2 +- libdwfl/Makefile.am| 2 +- libebl/Makefile.am | 2 +- libelf/Makefile.am | 3 ++- src/Makefile.am| 10 +- tests/Makefile.am | 4 ++-- 12 files changed, 26 insertions(+), 19 deletions(-) diff --git a/backends/Makefile.am b/backends/Makefile.am index 926464ae..347dad52 100644 --- a/backends/Makefile.am +++ b/backends/Makefile.am @@ -120,6 +120,7 @@ libebl_backends_pic_a_SOURCES = am_libebl_backends_pic_a_OBJECTS = $(libebl_backends_a_SOURCES:.c=.os) noinst_HEADERS = libebl_CPU.h common-reloc.c linux-core-note.c x86_corenote.c + EXTRA_DIST = $(modules:=_reloc.def) -MOSTLYCLEANFILES = $(am_libebl_backends_pic_a_OBJECTS) +MOSTLYCLEANFILES = $(am_libebl_backends_a_OBJECTS) $(am_libebl_backends_pic_a_OBJECTS) diff --git a/debuginfod/Makefile.am b/debuginfod/Makefile.am index 5ad4e188..45b5339f 100644 --- a/debuginfod/Makefile.am +++ b/debuginfod/Makefile.am @@ -125,8 +125,9 @@ uninstall: uninstall-am endif EXTRA_DIST = libdebuginfod.map -MOSTLYCLEANFILES = $(am_libdebuginfod_pic_a_OBJECTS) $(LIBDEBUGINFOD_SONAME) -CLEANFILES += $(am_libdebuginfod_pic_a_OBJECTS) libdebuginfod.so + +MOSTLYCLEANFILES = $(am_libdebuginfod_a_OBJECTS) $(am_libdebuginfod_pic_a_OBJECTS) $(LIBDEBUGINFOD_SONAME) +CLEANFILES = libdebuginfod.so # automake std-options override: arrange to pass LD_LIBRARY_PATH installcheck-binPROGRAMS: $(bin_PROGRAMS) diff --git a/lib/Makefile.am b/lib/Makefile.am index e324c18d..50c8036b 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -41,4 +41,5 @@ noinst_HEADERS = fixedsizehash.h libeu.h system.h dynamicsizehash.h list.h \ eu-config.h color.h printversion.h bpf.h \ atomics.h stdatomic-fbsd.h dynamicsizehash_concurrent.h \ eu-search.h locks.h + EXTRA_DIST = dynamicsizehash.c dynamicsizehash_concurrent.c diff --git a/libasm/Makefile.am b/libasm/Makefile.am index 1e6b63e8..324fd095 100644 --- a/libasm/Makefile.am +++ b/libasm/Makefile.am @@ -84,6 +84,8 @@ uninstall: uninstall-am rmdir --ignore-fail-on-non-empty $(DESTDIR)$(includedir)/elfutils noinst_HEADERS = libasmP.h symbolhash.h + EXTRA_DIST = libasm.map -CLEANFILES += $(am_libasm_pic_a_OBJECTS) libasm.so libasm.so.$(VERSION) +MOSTLYCLEANFILES = $(am_libasm_a_OBJECTS) $(am_libasm_pic_a_OBJECTS) libasm.so.$(VERSION) +CLEANFILES = libasm.so diff --git a/libcpu/Makefile.am b/libcpu/Makefile.am index 4ba1be56..32835237 100644 --- a/libcpu/Makefile.am +++ b/libcpu/Makefile.am @@ -101,6 +101,6 @@ bpf_disasm_CFLAGS = -Wno-format-nonliteral EXTRA_DIST = defs/i386 -MOSTLYCLEANFILES = $(am_libcpu_pic_a_OBJECTS) -CLEANFILES += $(foreach P,i386 x86_64,$P_defs $P.mnemonics) -MAINTAINERCLEANFILES = $(foreach P,i386 x86_64, $P_dis.h) +MOSTLYCLEANFILES = $(am_libcpu_a_OBJECTS) $(am_libcpu_pic_a_OBJECTS) $(i386_gendis_OBJECTS) +CLEANFILES = $(foreach P,i386 x86_64,$P_defs $P.mnemonics) +MAINTAINERCLEANFILES = $(foreach P,i386 x86_64, $P_defs $P_dis.h $P_parse.h) diff --git a/libdw/Makefile.am b/libdw/Makefile.am index 4b9c4413..62f4359e 100644 --- a/libdw/Makefile.am +++ b/libdw/Makefile.am @@ -152,5 +152,6 @@ noinst_HEADERS = libdwP.h memory-access.h dwarf_abbrev_hash.h \ EXTRA_DIST = libdw.map -MOSTLYCLEANFILES = $(am_libdw_pic_a_OBJECTS) libdw.so libdw.so.$(VERSION) +MOSTLYCLEANFILES = $(am_libdw_a_OBJECTS) $(am_libdw_pic_a_OBJECTS) libdw.so.$(VERSION) +CLEANFILES = libdw.so MAINTAINERCLEANFILES = $(srcdir)/known-dwarf.h diff --git a/libdwelf/Makefile.am b/libdwelf/Makefile.am index
Re: [PATCH 4/6] src: Prevent invalid include of binary into compilation
Hi, thanks for the reply, On Friday, October 11th, 2024 at 15:09, Aaron Merey wrote: > > I believe this issue was recently fixed in commit b426c4db31e7. Yeah, this looks like it handles the problem more directly, thanks for pointing it out. However, it would be nice if DEFAULT_INCLUDES was AC_SUBST'd instead of just blank for this case. Do you need me to resend the series without this patch? -- MCP
Re: [PATCH 0/6] Various portability fixes and organization
Hi Aaron, The first 3 patches of the series are pretty simple and helpful. I would like to see them in the next release, do they look ok? Without the first 2, we actually experience build errors due to config.h not being included or being included too late. The 3rd one prevents an error with our patched automake, it's unknown whether upstream automake would accept it due to the increased strictness in how the variable is defined, but it's a very easy adjustment anyway. -- Thanks for your consideration, MCP
[PATCH 2/3] Consolidate custom clean targets for coverage files
As reported by Mark: Since b2f225d6b ("Consolidate and add files to clean target variables") autoreconf (automake) produces these warnings: debuginfod/Makefile.am:130: warning: CLEANFILES multiply defined in condition TRUE ... config/eu.am:138: ... 'CLEANFILES' previously defined here debuginfod/Makefile.am:32: 'config/eu.am' included from here libasm/Makefile.am:91: warning: CLEANFILES multiply defined in condition TRUE ... config/eu.am:138: ... 'CLEANFILES' previously defined here libasm/Makefile.am:30: 'config/eu.am' included from here libcpu/Makefile.am:105: warning: CLEANFILES multiply defined in condition TRUE ... config/eu.am:138: ... 'CLEANFILES' previously defined here libcpu/Makefile.am:30: 'config/eu.am' included from here libdw/Makefile.am:156: warning: CLEANFILES multiply defined in condition TRUE ... config/eu.am:138: ... 'CLEANFILES' previously defined here libdw/Makefile.am:30: 'config/eu.am' included from here libelf/Makefile.am:142: warning: CLEANFILES multiply defined in condition TRUE ... config/eu.am:138: ... 'CLEANFILES' previously defined here libelf/Makefile.am:30: 'config/eu.am' included from here src/Makefile.am:47: warning: CLEANFILES multiply defined in condition TRUE ... config/eu.am:138: ... 'CLEANFILES' previously defined here src/Makefile.am:19: 'config/eu.am' included from here tests/Makefile.am:891: warning: CLEANFILES multiply defined in condition TRUE ... config/eu.am:138: ... 'CLEANFILES' previously defined here tests/Makefile.am:19: 'config/eu.am' included from here This is because config/eu.am defines a default "CLEANFILES". However, the list is only for the removal of coverage files. Since there is an exising custom clean rule for coverage in Makefile.am because there is a directory involved as well as files, further simplification of these rule definitions can resolve this. Define cleaning targets for coverage files in a single place and as a common definition for all generated Makefiles using a custom rule. This allows for avoiding the use of "CLEANFILES" variables for anything related to removing coverage files, and removing the usage of this variable where there is a conflict, as it is no longer needed to be defined there. * Makefile.am: remove variables and custom clean target. * config/eu.am: remove clean variables, add variables and custom clean target based on removed definitions. Fixes: b2f225d6b ("Consolidate and add files to clean target variables") Reported-by: Mark Wielaard Signed-off-by: Michael Pratt --- Makefile.am | 13 + config/eu.am | 9 - 2 files changed, 9 insertions(+), 13 deletions(-) diff --git a/Makefile.am b/Makefile.am index 9a8e5a52..e44bbe62 100644 --- a/Makefile.am +++ b/Makefile.am @@ -55,8 +55,6 @@ rpmbuild: dist if GCOV -COVERAGE_OUTPUT_FILE = $(PACKAGE_NAME).lcov -COVERAGE_OUTPUT_DIRECTORY = coverage COVERAGE_OUTPUT_INDEX_HTML = $(COVERAGE_OUTPUT_DIRECTORY)/index.html COVERAGE_TITLE = $(PACKAGE_NAME)-$(PACKAGE_VERSION) @@ -66,16 +64,7 @@ build_COVERAGE_DIRS = $(patsubst %,$(builddir)/%,$(COVERAGE_DIRS)) all_COVERAGE_DIRS = $(sort $(src_COVERAGE_DIRS) $(build_COVERAGE_DIRS)) LCOV_DIRS_ARGS = $(patsubst %,--directory=%,$(all_COVERAGE_DIRS)) -CLEANFILES = $(COVERAGE_OUTPUT_FILE) - -.PHONY: coverage coverage-clean - -clean-local: coverage-clean -distclean-local: coverage-clean - -coverage-clean: - -rm -rf $(COVERAGE_OUTPUT_DIRECTORY) - +.PHONY: coverage coverage: $(COVERAGE_OUTPUT_INDEX_HTML) @echo 'file://$(abs_builddir)/$(COVERAGE_OUTPUT_INDEX_HTML)' diff --git a/config/eu.am b/config/eu.am index 0b7dab5b..475d5836 100644 --- a/config/eu.am +++ b/config/eu.am @@ -135,7 +135,14 @@ else $(AM_V_CC)$(COMPILE.os) -c -o $@ $(fpic_CFLAGS) $(DEFS.os) $< endif -CLEANFILES = *.gcno *.gcda +COVERAGE_OUTPUT_DIRECTORY = coverage +COVERAGE_OUTPUT_FILE = $(PACKAGE_NAME).lcov + +.PHONY: clean-coverage +clean-local: clean-coverage +clean-coverage: + -rm -rf $(COVERAGE_OUTPUT_DIRECTORY) + -rm -f $(COVERAGE_OUTPUT_FILE) *.gcno *.gcda textrel_msg = echo "WARNING: TEXTREL found in '$@'" if FATAL_TEXTREL -- 2.30.2
[PATCH 3/3] Consolidate list of custom phony targets
Having a target defined as phony within a condition while another target is always defined as phony causes an automake warning: Makefile.am:67: warning: .PHONY was already defined in condition TRUE, which includes condition GCOV ... config/eu.am:141: ... '.PHONY' previously defined here Makefile.am:21: 'config/eu.am' included from here tests/Makefile.am:895: warning: .PHONY was already defined in condition TRUE, which includes condition GCOV ... config/eu.am:141: ... '.PHONY' previously defined here tests/Makefile.am:19: 'config/eu.am' included from here Instead, list all the custom targets that are phony in the common definitions in the eu.am file. Since it is all related to coverage at this moment, the list can be grouped as it is instead of moved or split. * Makefile.am: remove .PHONY list in conditional * config/eu.am: add coverage target to .PHONY list * tests/Makefile.am: remove .PHONY list in conditional Signed-off-by: Michael Pratt --- Makefile.am | 1 - config/eu.am | 3 ++- tests/Makefile.am | 1 - 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/Makefile.am b/Makefile.am index e44bbe62..3a181d75 100644 --- a/Makefile.am +++ b/Makefile.am @@ -64,7 +64,6 @@ build_COVERAGE_DIRS = $(patsubst %,$(builddir)/%,$(COVERAGE_DIRS)) all_COVERAGE_DIRS = $(sort $(src_COVERAGE_DIRS) $(build_COVERAGE_DIRS)) LCOV_DIRS_ARGS = $(patsubst %,--directory=%,$(all_COVERAGE_DIRS)) -.PHONY: coverage coverage: $(COVERAGE_OUTPUT_INDEX_HTML) @echo 'file://$(abs_builddir)/$(COVERAGE_OUTPUT_INDEX_HTML)' diff --git a/config/eu.am b/config/eu.am index 475d5836..e4fcbd1a 100644 --- a/config/eu.am +++ b/config/eu.am @@ -138,7 +138,8 @@ endif COVERAGE_OUTPUT_DIRECTORY = coverage COVERAGE_OUTPUT_FILE = $(PACKAGE_NAME).lcov -.PHONY: clean-coverage +.PHONY: clean-coverage coverage + clean-local: clean-coverage clean-coverage: -rm -rf $(COVERAGE_OUTPUT_DIRECTORY) diff --git a/tests/Makefile.am b/tests/Makefile.am index 44cbb825..8f087798 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -892,7 +892,6 @@ CLEANFILES = $(BUILT_SOURCES) if GCOV check: check-am coverage -.PHONY: coverage coverage: -$(srcdir)/coverage.sh endif -- 2.30.2
[PATCH 1/3] Makefile.am: include common eu.am definitions
Some definitions in Makefile.am can be moved to the common definitions in config/eu.am, but for them to apply to the top-level Makefile after moving, eu.am must be added as an include statement. Except for "CLEANFILES", handled in the next commit, there are no definitions in eu.am that are defined in Makefile.am, so there are no other conflicts or overrides between the two. Signed-off-by: Michael Pratt --- Makefile.am | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Makefile.am b/Makefile.am index 92130b57..9a8e5a52 100644 --- a/Makefile.am +++ b/Makefile.am @@ -18,6 +18,8 @@ ## You should have received a copy of the GNU General Public License ## along with this program. If not, see <http://www.gnu.org/licenses/>. ## +include $(top_srcdir)/config/eu.am + ACLOCAL_AMFLAGS = -I m4 # automake already tells which subdir is being entered. -- 2.30.2
Re: [PATCH] Cleanup Makefile.am CLEANFILES definitions
Hi Mark, > Since b2f225d6bff8 ("Consolidate and add files to clean target variables") > autoreconf (automake) produces these warnings: oops, sorry... > This is because config/eu.am defines a default CLEANFILES. So those > Makefile.am files should add to CLEANFILES with += instead of > redefining CLEANFILES with =. May I suggest to instead simply use "DISTCLEANFILES" for what is in eu.am? It's not being used anywhere else currently... If that's no good, I would then like to see a '+=' in all the "*CLEANFILES" definitions in each level for each file so it's not confusing or looking like a possible mistake. -- MCP
Re: [PATCH] Cleanup Makefile.am CLEANFILES definitions
Hi Mark, On 11/21/24 7:44 PM, Mark Wielaard wrote: > Hi Michael, > > On Tue, Nov 19, 2024 at 04:18:17AM +, Michael Pratt wrote: > > > > > This is because config/eu.am defines a default CLEANFILES. So those > > > Makefile.am files should add to CLEANFILES with += instead of > > > redefining CLEANFILES with =. > > > > May I suggest to instead simply use > > "DISTCLEANFILES" for what is in eu.am? > > It's not being used anywhere else currently... > > But aren't DISTCLEANFILES only remove for make distclean? The *.gcno > *.gcda could be added to MOSTLYCLEANFILES since you would normally > want to regenerate them. I am not sure that would resolve your issue > though. You would be a better judge of when the files should be removed, I'm not as familiar with their purpose. I was imagining that only maintainers or only those who develop like the maintainers would bother with these files, so making it closer to the "maintainer-clean" target would be good enough. Since the DISTCLEANFILES variable is currently unused it would be one way to resolve the issue, although provided that it's not added elsewhere later... so maybe not the best step. > > If that's no good, I would then like to see a '+=' > > in all the "*CLEANFILES" definitions in each level for each file > > so it's not confusing or looking like a possible mistake. > > You mean even for MAINTAINERCLEANFILES and MOSTLYCLEANFILES? and even > for those (config/Makefile.am ./Makefile.am doc/Makefile.am) that > don't include eu.am (and also don't use CLEANFILES, except for the > top-level one)? The Makefile.am files that don't include eu.am also don't have "CLEANFILES" variables... except for the top-level one... Ironically, the CLEANFILES definitions in both eu.am and the top-level Makefile.am seem to be for the same purpose which is coverage files... Further simplification can also be a solution to this, so I'm going to send a small patch set for you all to consider. It's likely a better idea than the 3 ideas presented here so far. > The "rule" now seems to be: > - When you use CLEANFILES you should now always use +=. > = MAINTAINERCLEANFILES and MOSTLYCLEANFILES uses =. > > Is that "rule" really that confusing? It's not written anywhere that this is the case so someone seeing this for the first time would have to do some digging to see why it is there provided that they realize there is a good reason for it. I think several people including myself see the subdirectories as independent and would consider the list of files to clean being independent to logically follow from that. I don't really see it as a rule, rather just an inconsistency. It just happens to be the way that the first person to write these cleaning steps happen to do so when there's really many ways to write it. And again, I'm sorry for not noticing this earlier. For whatever reason I didn't see the pattern, and the '+=' looked unnecessary at first glance, also since some other instances of the '+=' I saw were because of other lines in the same file in other cases. For me, a rule would be to write the rules the most simple way whenever possible, leading to simpler and smaller automake usage. -- MCP
[PATCH] Replace usage of ar with stored library manifest files
The ar program is called to assemble a list of objects within each archive to assist in building combined libraries, however make already has this information when processing the subdirectory for that respective library. The list can be saved in a "manifest" file instead of being generated whenever it is needed for use with other subdirectories. Even though the difference in time is insignificant, a simple "echo" and "cat" is as much as 10 times faster than a call to "ar t" for printing the archive members. Since elfutils builds ar, this also removes the awkward circular dependency where an installation of ar is required to build the libraries for ar. Additionally, not every version of ar is equally portable, as native versions of ar on macOS and other BSD-like distributions may print out a special archive member like "__.SYMDEF" which is not a compiled object but rather just metadata from ranlib, leading to a build failure. Avoid these limitations by removing usage of ar and adding build and clean rules for the usage of archive manifest files. * .gitignore: exclude ".manifest" file extension. * backends/Makefile.am: add manifest file build and clean rules. * debuginfod/Makefile.am: Likewise. * lib/Makefile.am: Likewise. * libasm/Makefile.am: Likewise. * libcpu/Makefile.am: Likewise. * libdw/Makefile.am: Likewise, and set object lists to manifest contents. * libdwelf/Makefile.am: Likewise. * libdwfl/Makefile.am: Likewise. * libebl/Makefile.am: Likewise. * libelf/Makefile.am: Likewise, and set object lists to manifest contents. * src/Makefile.am: Likewise. Signed-off-by: Michael Pratt --- .gitignore | 1 + backends/Makefile.am | 6 ++ debuginfod/Makefile.am | 7 ++- lib/Makefile.am| 7 +++ libasm/Makefile.am | 7 ++- libcpu/Makefile.am | 7 ++- libdw/Makefile.am | 17 +++-- libdwelf/Makefile.am | 6 ++ libdwfl/Makefile.am| 6 ++ libebl/Makefile.am | 6 ++ libelf/Makefile.am | 9 +++-- src/Makefile.am| 7 ++- 12 files changed, 74 insertions(+), 12 deletions(-) diff --git a/.gitignore b/.gitignore index 8bcd88d7..b21d7490 100644 --- a/.gitignore +++ b/.gitignore @@ -2,6 +2,7 @@ *.a *.gcda *.gcno +*.manifest *.o *.orig *.os diff --git a/backends/Makefile.am b/backends/Makefile.am index 347dad52..540d0c6c 100644 --- a/backends/Makefile.am +++ b/backends/Makefile.am @@ -123,4 +123,10 @@ noinst_HEADERS = libebl_CPU.h common-reloc.c linux-core-note.c x86_corenote.c EXTRA_DIST = $(modules:=_reloc.def) +EXTRA_libebl_backends_a_DEPENDENCIES = libebl_backends.manifest + +libebl_backends.manifest: $(libebl_backends_a_OBJECTS) + $(AM_V_GEN)echo $^ > $@ + MOSTLYCLEANFILES = $(am_libebl_backends_a_OBJECTS) $(am_libebl_backends_pic_a_OBJECTS) +CLEANFILES = $(EXTRA_libebl_backends_a_DEPENDENCIES) diff --git a/debuginfod/Makefile.am b/debuginfod/Makefile.am index 45b5339f..4727e5fa 100644 --- a/debuginfod/Makefile.am +++ b/debuginfod/Makefile.am @@ -126,8 +126,13 @@ endif EXTRA_DIST = libdebuginfod.map +EXTRA_libdebuginfod_a_DEPENDENCIES = libdebuginfod.manifest + +libdebuginfod.manifest: $(libdebuginfod_a_OBJECTS) + $(AM_V_GEN)echo $^ > $@ + MOSTLYCLEANFILES = $(am_libdebuginfod_a_OBJECTS) $(am_libdebuginfod_pic_a_OBJECTS) $(LIBDEBUGINFOD_SONAME) -CLEANFILES = libdebuginfod.so +CLEANFILES = libdebuginfod.so $(EXTRA_libdebuginfod_a_DEPENDENCIES) # automake std-options override: arrange to pass LD_LIBRARY_PATH installcheck-binPROGRAMS: $(bin_PROGRAMS) diff --git a/lib/Makefile.am b/lib/Makefile.am index 45b351c1..bf5f9ee2 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -43,3 +43,10 @@ noinst_HEADERS = fixedsizehash.h libeu.h system.h dynamicsizehash.h list.h \ eu-search.h locks.h EXTRA_DIST = dynamicsizehash.c dynamicsizehash_concurrent.c + +EXTRA_libeu_a_DEPENDENCIES = libeu.manifest + +libeu.manifest: $(libeu_a_OBJECTS) + $(AM_V_GEN)echo $^ > $@ + +CLEANFILES = $(EXTRA_libeu_a_DEPENDENCIES) diff --git a/libasm/Makefile.am b/libasm/Makefile.am index 324fd095..969db935 100644 --- a/libasm/Makefile.am +++ b/libasm/Makefile.am @@ -87,5 +87,10 @@ noinst_HEADERS = libasmP.h symbolhash.h EXTRA_DIST = libasm.map +EXTRA_libasm_a_DEPENDENCIES = libasm.manifest + +libasm.manifest: $(libasm_a_OBJECTS) + $(AM_V_GEN)echo $^ > $@ + MOSTLYCLEANFILES = $(am_libasm_a_OBJECTS) $(am_libasm_pic_a_OBJECTS) libasm.so.$(VERSION) -CLEANFILES = libasm.so +CLEANFILES = libasm.so $(EXTRA_libasm_a_DEPENDENCIES) diff --git a/libcpu/Makefile.am b/libcpu/Makefile.am index 2e87021b..df16439c 100644 --- a/libcpu/Makefile.am +++ b/libcpu/Makefile.am @@ -103,6 +103,11 @@ bpf_disasm_CFLAGS = -Wno-format-nonliteral EXTRA_DIST = defs/i386 +EXTRA_libcpu_a_DEPENDENCIES = libcpu.manifest + +libcpu.manifest: