src/work/makefile
author jacint
Wed, 05 May 2004 17:24:06 +0000
changeset 535 bd79aa43f299
parent 417 4ce3d5f675ea
child 577 e8703f0a6e2f
permissions -rw-r--r--
(none)
beckerjc@149
     1
INCLUDEDIRS ?= -I../include -I. -I./{marci,jacint,alpar,klao,akos}
marci@409
     2
CXXFLAGS = -g -O3 -W -Wall $(INCLUDEDIRS) -ansi -pedantic
alpar@3
     3
klao@347
     4
BINARIES ?= bin_heap_demo
alpar@3
     5
klao@34
     6
# Hat, ez elismerem, hogy nagyon ronda, de mukodik minden altalam
klao@34
     7
# ismert rendszeren :-)  (Misi)
marci@417
     8
ifdef GCCVER
marci@417
     9
CXX := g++-$(GCCVER)
marci@417
    10
else
marci@417
    11
CXX := $(shell type -p g++-3.3 || type -p g++-3.2 || type -p g++-3.0 || type -p g++-3 || echo g++)
marci@417
    12
endif
marci@417
    13
klao@493
    14
ifdef DEBUG
klao@493
    15
CXXFLAGS += -DDEBUG
klao@493
    16
endif
klao@493
    17
klao@34
    18
CC := $(CXX)
klao@34
    19
klao@34
    20
klao@34
    21
all: $(BINARIES)
klao@34
    22
klao@34
    23
################
klao@34
    24
# Minden binarishoz egy sor, felsorolva, hogy mely object file-okbol
klao@34
    25
# all elo.
klao@34
    26
# Kiveve ha siman file.cc -> file  esetrol van szo, amikor is nem kell
klao@34
    27
# irni semmit.
klao@34
    28
klao@34
    29
#proba: proba.o seged.o
klao@34
    30
klao@34
    31
################
klao@34
    32
klao@132
    33
klao@132
    34
.depend dep depend:
marci@301
    35
	-$(CXX) $(CXXFLAGS) -M $(BINARIES:=.cc) > .depend
klao@34
    36
klao@34
    37
makefile: .depend
klao@34
    38
sinclude .depend
alpar@3
    39
alpar@3
    40
clean:
klao@34
    41
	$(RM) *.o $(BINARIES) .depend
alpar@7
    42
klao@34
    43
.PHONY: all clean dep depend