[Top][All Lists]

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

Re: no rule to make asm targets

From: Jari Strand
Subject: Re: no rule to make asm targets
Date: Wed, 06 Dec 2006 16:46:11 +0200


From: Stepan Kasal <address@hidden>
To: Jari Strand <address@hidden>
CC: address@hidden
Subject: Re: no rule to make asm targets
Date: Wed, 6 Dec 2006 11:52:19 +0100


On Wed, Dec 06, 2006 at 06:21:09AM +0200, Jari Strand wrote:
> >For example, does bin_PROGRAMS really contain only one program?
> Yes, [...]

OK, in that case there is no need to use per-target flags.

Alright, I was actually planning on supporting more targets later on and now that this didnt work I didnt want rush to add support for more targets. I have now however changed it to not to use the per-target settings but the global (AM_) target.

Let me show an example:

bin_PROGRAMS = first second third
first_SOURCES = first.c
second_SOURCES = second.c
third_SOURCES = third.c

second_CFLAGS = ...

In this example, `AM_CFLAGS' is used for all programs, with one
exception: when compiling program `third', `third_CFLAGS' is used

Thanks for the demonstration! I suppose you meant "second" as that's what you typed but I understand.

This `third_CFLAGS' is called per-target variable, and overrides the
corresponding general one AM_CFLAGS.

The mechanism is the same in your case, when you are using *_CPPFLAGS
instead of *_CFLAGS.

Since you have only one program, you can set `AM_CPPFLAGS' as needed
for the program `editorD', and there is no need to use the override

Then, because of some internal mechanisms of Automake, the suffix
rule `.asm.o' will be used, and you can redefine it if you like.

Start with the following code, adding back the things you removed
to simplify the example.

> >bin_PROGRAMS = editorD
> >TLIB_PATH = /home
> >AM_CPPFLAGS = -I$(TLIB_PATH)/openal/LINUX -I$(TLIB_PATH)/lungif \
> >       -I$(TLIB_PATH)/lungif -I$(TLIB_PATH)/opengl2d3d \
> >       -I$(TLIB_PATH)/zlib -I$(TLIB_PATH)/lpng -I$(TLIB_PATH)/ljpeg \
> >       -I$(TLIB_PATH)/vorbis/include -DEDITOR_BUILD
> >editorD_SOURCES = someAsm.asm
> >.asm.o:
> >       $(NASM_PATH) -o $@ -f elf -dLINUX $<

Ok it's changed now and the new object files were built. Unfortunately this did not solve the asm object file problem but the error remains the same.

Have a nice day,
        Stepan Kasal

Thank you, good day to you too.


Express yourself instantly with MSN Messenger! Download today it's FREE!

reply via email to

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