[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
make not work on some weired Makefile
From: |
fsshl |
Subject: |
make not work on some weired Makefile |
Date: |
30 Sep 2005 22:43:33 -0700 |
User-agent: |
G2/0.2 |
I like to compile some source, its Makefile is
----------------------------------------------------
# cat Makefile
# SPECapc Makefile for UNIX and Linux systems
# Contents \uffff Copyright 2001, Standard Performance Evaluation
Corporation
#
# Modification History:
# 1/13/2002, Joe Edwards, Cognitive Advantage, Inc., Nashua NH
# Modified for ProE Version 2001 and lowercase file names.
#
# You must set the flags below as required to compile on the target
system
# hp8k ANSI needed for prototypes
# COPTS = -Ae
CFLAGS = $(COPTS) -O -c
LDFLAGS = -lX11
LINKER = $(LD)
LINKER = $(CC)
# ibm_rs6000 uses xlc_r
# LINKER = xlc_r
clean:
rm $(PRO_MACHINE_TYPE)/utilities.o
$(PRO_MACHINE_TYPE)/proescore.o $(PRO_MACHINE_TYPE)/config.o
$(PRO_MACHINE_TYPE)/proescore $(PRO_MACHINE_TYPE)/config
all: config proescore
config: $(PRO_MACHINE_TYPE)/config.o $(PRO_MACHINE_TYPE)/utilities.o
$(LINKER) -o $(PRO_MACHINE_TYPE)/config
$(PRO_MACHINE_TYPE)/config.o $(PRO_MACHINE_TYPE)/utilities.o $(LDFLAGS)
proescore: $(PRO_MACHINE_TYPE)/proescore.o
$(PRO_MACHINE_TYPE)/utilities.o
$(LINKER) -o $(PRO_MACHINE_TYPE)/proescore
$(PRO_MACHINE_TYPE)/proescore.o $(PRO_MACHINE_TYPE)/utilities.o -lm
-lX11
$(PRO_MACHINE_TYPE)/utilities.o: utilities.c
$(CC) $(CFLAGS) utilities.c -o$(PRO_MACHINE_TYPE)/utilities.o
$(PRO_MACHINE_TYPE)/proescore.o: proescore.c
$(CC) $(CFLAGS) proescore.c -o$(PRO_MACHINE_TYPE)/proescore.o
$(PRO_MACHINE_TYPE)/config.o: config.c
$(CC) $(CFLAGS) config.c -o$(PRO_MACHINE_TYPE)/config.o
----------------------------------------------------------------------------------
so I type make, but it response
---------
# make
rm /utilities.o /proescore.o /config.o /proescore /config
rm: cannot remove `/utilities.o': No such file or directory
rm: cannot remove `/proescore.o': No such file or directory
rm: cannot remove `/config.o': No such file or directory
rm: cannot remove `/proescore': No such file or directory
rm: cannot remove `/config': No such file or directory
make: *** [clean] Error 1
------------------
for me, it seems Makefile did not call c compiler before clean(rm)
please help
charles
- make not work on some weired Makefile,
fsshl <=