src/work/makefile
author deba
Sat, 09 Apr 2005 19:30:49 +0000
changeset 1331 7e93d3f0406d
parent 867 f3cc65f9fb6b
permissions -rw-r--r--
Documentation improvments.
klao@618
     1
INCLUDEDIRS ?= -I.. -I. -I./{marci,jacint,alpar,klao,akos}
klao@1067
     2
CXXFLAGS += -g -O2 -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