On Tue, Nov 12, 2024 at 07:05:42PM +0000, Gavin Smith wrote: > I do not remember removing a gnulib module being this difficult.
I worked around it by copying the command from gnulib/lib/Makefile.am and removing the "copy-file" line: ../../../../gnulib/gnulib-tool --import \ --lib=libgnu \ --source-base=gnulib/lib \ --m4-base=gnulib/m4 \ --po-base=gnulib/po \ --doc-base=doc \ --tests-base=tests \ --aux-dir=build-aux \ --no-conditional-dependencies \ --libtool \ --macro-prefix=gl \ --po-domain=texinfo_tp \ euidaccess \ getline \ iconv \ libunistring \ locale \ obstack \ setenv \ strchrnul \ strndup \ uchar \ unicase/u8-tolower \ unicase/u8-toupper \ unictype/category-L \ unictype/category-M \ unictype/category-Mn \ unictype/category-Nd \ unictype/category-test \ unictype/ctype-upper \ unictype/property-alphabetic \ unictype/property-join-control \ unictype/property-test \ uninorm/nfc \ uninorm/nfkd \ uninorm/u8-normalize \ unistr/u32-next \ unistr/u8-mbsnlen \ unistr/u8-mbtouc \ unistr/u8-next \ unistr/u8-strlen \ unistr/u8-strmbtouc \ unistr/u8-uctomb \ uniwidth/u8-strwidth \ uniwidth/u8-width \ unsetenv \ vasprintf It leads to 132 files being deleted and numerous dependencies disappearing: $ git diff gnulib/m4/gnulib-comp.m4 | grep "^- # Code" - # Code from module acl-permissions: - # Code from module basename-lgpl: - # Code from module binary-io: - # Code from module c-ctype: - # Code from module c-strcase: - # Code from module c-strcaseeq: - # Code from module c32isprint: - # Code from module calloc-gnu: - # Code from module calloc-posix: - # Code from module clock-time: - # Code from module cloexec: - # Code from module copy-file: - # Code from module copy-file-range: - # Code from module double-slash-root: - # Code from module error: - # Code from module error-h: - # Code from module fstat: - # Code from module full-write: - # Code from module getprogname: - # Code from module gettime: - # Code from module gettimeofday: - # Code from module hard-locale: - # Code from module ialloc: - # Code from module ignore-value: - # Code from module intprops: - # Code from module localcharset: - # Code from module lstat: - # Code from module mbrtoc32: - # Code from module mbrtowc: - # Code from module mbsinit: - # Code from module minmax: - # Code from module open: - # Code from module qcopy-acl: - # Code from module quote: - # Code from module quotearg: - # Code from module quotearg-simple: - # Code from module raise: - # Code from module read: - # Code from module reallocarray: - # Code from module safe-read: - # Code from module safe-write: - # Code from module setlocale-null: - # Code from module setlocale-null-unlocked: - # Code from module signal-h: - # Code from module strerror: - # Code from module strerror-override: - # Code from module sys_time: - # Code from module timespec: - # Code from module unictype/ctype-print: - # Code from module utime: - # Code from module utime-h: - # Code from module utimens: - # Code from module write: - # Code from module xalloc: - # Code from module xalloc-die: It is an awful lot just to copy a couple of files. The only compilation error is in convert/convert_html.c: convert/convert_html.c:23:10: fatal error: copy-file.h: No such file or directory 23 | #include "copy-file.h" | ^~~~~~~~~~~~~ compilation terminated. Note this is for copying the JavaScript files with INFO_JS_DIR, which is hardly used anyway. In the worst case, it would be possible to copy a file with fopen on a source and destination files, fread from the source file and fwrite to the destination file, although this would be more inefficient than dedicated file copying functionality.