[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Should gnulib lib_SOURCES contain .h files? also, splitting up ftoas
From: |
Bruno Haible |
Subject: |
Re: Should gnulib lib_SOURCES contain .h files? also, splitting up ftoastr |
Date: |
Tue, 11 Jan 2011 23:06:56 +0100 |
User-agent: |
KMail/1.9.9 |
Hi Paul,
> Emacs needs the dtoastr function, but not ftoastr or ldtoastr.
> To save build time, it'd be nice if it could build just dtoastr.
> The easiest way I can think of to do that is to split up the
> existing ftoastr module (which supports all three functions)
> into three modules: ftoastr, dtoastr, ldtoastr, one for
> each function.
Yes, that's the most sensible way to do it.
When you do this, the files lib/ftoastr.h, lib/ftoastr.c, and m4/c-strtod.m4
would be listed as part of each of the 3 modules. Whereas lib_SOURCES would
contain just one file in each case:
lib_SOURCES += ftoastr.c for module ftoastr
lib_SOURCES += dtoastr.c for module dtoastr
lib_SOURCES += ldtoastr.c for module ldtoastr
> While looking into this I noticed that ftoastr, like some
> but not all other modules, puts a .h file into lib_SOURCES:
>
> lib_SOURCES += ftoastr.h ftoastr.c dtoastr.c ldtoastr.c
You can list or omit .h files in lib_SOURCES; it has no effect.
That's because Automake knows that .h files cannot be compiled
to object files.
> I see that other modules are inconsistent in this area.
Yes, but it's not worth spending time on fixing this inconsistency.
Bruno