File: Makefile

package info (click to toggle)
vlevel 0.5.2-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 380 kB
  • sloc: cpp: 1,429; makefile: 106; sh: 7
file content (53 lines) | stat: -rw-r--r-- 1,815 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# This file is part of VLevel, a dynamic volume normalizer.
#
# Copyright 2003 Tom Felker <tcfelker@mtco.com>
#
# This library is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation; either version 2.1 of the
# License, or (at your option) any later version.
#
# This library is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
# USA

# This is evil, but it makes implicit link rules use g++, not gcc
CC = $(CXX)

.PHONY: all
all: vlevel-bin

.PHONY: install
install: all
	cp -f vlevel-bin $(PREFIX)/bin/

.PHONY: clean
clean:
	-rm -f *.o vlevel-bin

# This isn't ideal - if ../volumeleveler/volumeleveler.cpp was changed,
# but make wasn't yet run there, then the .o file won't be new, so
# the project will be improperly built.  Also, if volumeleveler.o doesn't
# exist yet, then make won't build it.  Unfortunately, it's discouraged
# to make it a .PHONY, and besides, that causes relinking every time
# make is run here, even during install (which leaves root's files).
# Make sucks.

../volumeleveler/volumeleveler.o:
	$(MAKE) -C ../volumeleveler all

vlevel-bin: vlevel-bin.o \
            commandline.o \
            ../volumeleveler/volumeleveler.o

vlevel-bin.o: vlevel-bin.cpp \
              commandline.h \
              ../volumeleveler/volumeleveler.h \

commandline.o: commandline.cpp commandline.h