automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: c file used as a make file


From: Russ Allbery
Subject: Re: c file used as a make file
Date: Tue, 22 Mar 2011 00:06:14 -0700
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux)

Paul Elliott <address@hidden> writes:

> I have a c library that currently uses an old style Makefile that I want
> to convert to auto*tools.

> One .c file is used as a .h file. That is, it is included by another .c
> file and it should not be itself compiled. Why the author did this I do
> not know, but I do not want to change the author's source or change or
> rename any files.

> How do I tell auto*tools to treat this file as a .h file? That is, do
> not try to compile this file itself, and do include it in the files to
> be distributed.

The easiest way is to add it to the EXTRA file list for the given target.
In other words, if this is used to build libfoo.a, then add:

EXTRA_libfoo_a_SOURCES = foo.c

to your Makefile.am.

-- 
Russ Allbery (address@hidden)             <http://www.eyrie.org/~eagle/>



reply via email to

[Prev in Thread] Current Thread [Next in Thread]