www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/09/06/13:50:15

Date: Sun, 6 Sep 1998 20:53:33 -0200 (GMT+2)
From: Balazs Miklos <mbalazs AT kabelkon DOT ro>
To: djgpp AT delorie DOT com
Subject: need help with make
Message-ID: <Pine.LNX.3.96.980906204013.96A-100000@phantom.pi>
MIME-Version: 1.0

Hi! 
I have two makefiles, the second is called from the first.
In the second makefile, I need to call 'nasm', and I do it using the
variables exported from the first makefile (I have tried it to call
directly). When nasm runs, it sais: more than one input file specified.
If I type in a shell exactly the same command line make executed, it
works. What could be the problem?

1st makefile:

CPU = 386
POS_PATH = /pos/kernel
INCLUDE = $(POS_PATH)/include/

export NASM = nasm
export ASMFLAGS = -fcoff -i$(INCLUDE)
export GCC = gcc
export CFLAGS = -c -O3 -m$(CPU) -I$(INCLUDE)
export LD = ld
export OBJCOPY = objcopy

all : bin

bin : dummy
	@$(MAKE) -C src

clean :
	@$(MAKE) clean -C src

dummy :

2nd makefile:



OBJFILES = main.o memory.o cmain.o

all : pos.bin

pos.bin : $(OBJFILES)
	$(LD) -Ttext 200000 -o pos.a $(OBJFILES)
	$(OBJCOPY) -I a.out-i386 -O binary pos.a pos.bin

main.o: main.asm
	$(NASM) $(ASMFLAGS) main.asm
#         ^^^^^^^^ here is the problem.
	
cmain.o : 
	@$(MAKE) -C c	

memory.o:
	@$(MAKE) -C memory

clean :
	del *.o
	@$(MAKE) clean -C memory
	@$(MAKE) clean -C c


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019