LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   make does not say 'up to date' (https://www.linuxquestions.org/questions/programming-9/make-does-not-say-up-to-date-236090/)

ananthbv 09-28-2004 01:15 AM

make does not say 'up to date'
 
hi all,
i have a makefile which in turn runs several other makefiles. 'make' runs fine but does not say 'up to date' when i run the same makefile without making any changes to the relevant files. what could be the reason(s)?

Hko 09-28-2004 06:01 AM

Could you post your Makefile(s) please.
Without it, we can't do anything but guess...

One easy guess would be though:
Have you specified any dependencies like the red part below?
Code:

prog: main.c
<tab>  gcc -c -o prog main.c


ananthbv 09-28-2004 06:59 AM

no Hko, there is no
Code:

prog: main.c
and thats a humongous makefile, containing a lot of sub-makefiles, but these are the essential details.
these are the sub-makefiles:
Code:

a.mk aa.mk ... ae.mk
b.mk ...
c.mk  ...
d.mk  ...
e.mk  ...
f.mk  ...
g.mk  ...
h.mk  ...
i.mk  ...
j.mk  ...
.
.
.
z.mk  ...  ze.mk

each of these makefiles contain something like this. pls assume that all the symbols in $(...) have been predefined.

Code:

#  a.mk

COBOL_OBJECTS=\
                  $(SOME_DIR)/cob1.o \
                  $(SOME_DIR)/cob2.o

PASCAL_OBJECTS=\
                  $(ANOTHER_DIR)/pas1.o \
                  $(ANOTHER_DIR)/pas2.o

a: $(COBOL_OBJECTS) $(PASCAL_OBJECTS)
        $(COB) -Z $(COBOL_OBJECTS) $(PASCAL_OBJECTS) -o $(LIB_DIR)/liba.sl

.cbl.o:
        $(COBOL) $(COBOPTS) -c $< -o $@

.p.o:
        $(PASCAL) $(PASOPTS) ...

clean:
        <rm commands>

thats about the sub-makefiles. the actual 'makefile' is like this
Code:

# final makefile

all: MAKE_SOME
          make -f a.mk  a
          make -f b.mk  b
          make -f c.mk  c
          make -f d.mk  d
          make -f e.mk  e
          .
          .
          .
          make -f z.mk  z

MAKE_SOME:
          make -f aa.mk  aa
          make -f ab.mk  ab
          make -f ac.mk  ac
          make -f ad.mk  ad
          make -f az.mk  ae

clean:
          make -f a.mk  clean
          make -f b.mk  clean
          make -f c.mk  clean
          make -f d.mk  clean
          make -f e.mk  clean
          .
          .
          .
          make -f z.mk  clean

# and so on

is this enough description? thanks for any help.


All times are GMT -5. The time now is 05:29 PM.