blob: aeddb47766275f05b98eb9f1ad4b014c9a2564e8 [file] [log] [blame]
Josh Coalson6b05bc52001-06-08 00:13:21 +00001# FLAC - Free Lossless Audio Codec
Josh Coalson1152f9f2002-01-26 18:05:12 +00002# Copyright (C) 2001,2002 Josh Coalson
Josh Coalson6b05bc52001-06-08 00:13:21 +00003#
4# This program is part of FLAC; you can redistribute it and/or
5# modify it under the terms of the GNU General Public License
6# as published by the Free Software Foundation; either version 2
7# of the License, or (at your option) any later version.
8#
9# This program is distributed in the hope that it will be useful,
10# but WITHOUT ANY WARRANTY; without even the implied warranty of
11# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12# GNU General Public License for more details.
13#
14# You should have received a copy of the GNU General Public License
15# along with this program; if not, write to the Free Software
16# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
17
Josh Coalsonbb7f6b92000-12-10 04:09:52 +000018#
19# GNU Makefile
20#
21# Useful targets
22#
23# all : build all libraries and programs in the default configuration (currently 'release')
24# debug : build all libraries and programs in debug mode
25# release : build all libraries and programs in release mode
26# test : run the unit and stream tests
27# clean : remove all non-distro files
28#
29
Josh Coalson1f99eac2002-08-23 06:45:23 +000030.PHONY: doc libFLAC libFLAC++ libOggFLAC libOggFLAC++ share plugin_common plugin_xmms flac metaflac test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_streams
31all: doc libFLAC libFLAC++ libOggFLAC libOggFLAC++ share plugin_common plugin_xmms flac metaflac test_libFLAC test_libFLAC++ test_libOggFLAC test_libOggFLAC++ test_streams
Josh Coalsonbb7f6b92000-12-10 04:09:52 +000032
33DEFAULT_CONFIG = release
34
35CONFIG = $(DEFAULT_CONFIG)
36
37debug : CONFIG = debug
38release : CONFIG = release
39
40debug : all
41release : all
42
Josh Coalsonef5c2f82002-07-24 06:13:41 +000043doc:
44 (cd $@ ; $(MAKE) -f Makefile.lite)
45
Josh Coalsonbb7f6b92000-12-10 04:09:52 +000046libFLAC:
Josh Coalson0cf199f2001-01-19 22:34:26 +000047 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
Josh Coalsonbb7f6b92000-12-10 04:09:52 +000048
Josh Coalsona86f8702002-08-20 04:03:24 +000049libFLAC++: libFLAC
Josh Coalsonaae225a2002-05-17 06:07:26 +000050 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
51
Josh Coalsona86f8702002-08-20 04:03:24 +000052libOggFLAC: libFLAC
Josh Coalsonc49380d2002-08-07 17:38:08 +000053 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
54
Josh Coalsona86f8702002-08-20 04:03:24 +000055libOggFLAC++: libFLAC
Josh Coalsonc49380d2002-08-07 17:38:08 +000056 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
57
Josh Coalsonaae225a2002-05-17 06:07:26 +000058share:
59 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
60
Josh Coalsonc49380d2002-08-07 17:38:08 +000061flac: libFLAC libOggFLAC
Josh Coalson0cf199f2001-01-19 22:34:26 +000062 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
Josh Coalsonbb7f6b92000-12-10 04:09:52 +000063
Josh Coalson57ba6f42002-06-07 05:27:37 +000064metaflac: libFLAC share
Josh Coalson74766922001-02-23 23:15:00 +000065 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
66
Josh Coalson1f99eac2002-08-23 06:45:23 +000067plugin_common: libFLAC
68 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
69
70plugin_xmms: libFLAC plugin_common
Josh Coalson0cf199f2001-01-19 22:34:26 +000071 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
Josh Coalson614ba672000-12-22 22:49:09 +000072
Josh Coalsonbb7f6b92000-12-10 04:09:52 +000073test_streams: libFLAC
Josh Coalson0cf199f2001-01-19 22:34:26 +000074 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
Josh Coalsonbb7f6b92000-12-10 04:09:52 +000075
Josh Coalson57ba6f42002-06-07 05:27:37 +000076test_libFLAC: libFLAC
77 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
78
79test_libFLAC++: libFLAC libFLAC++
Josh Coalson0cf199f2001-01-19 22:34:26 +000080 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
Josh Coalsonbb7f6b92000-12-10 04:09:52 +000081
Josh Coalsona86f8702002-08-20 04:03:24 +000082test_libOggFLAC: libFLAC libOggFLAC
83 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
84
85test_libOggFLAC++: libFLAC libOggFLAC libOggFLAC++
86 (cd src/$@ ; $(MAKE) -f Makefile.lite $(CONFIG))
87
Josh Coalsonbb7f6b92000-12-10 04:09:52 +000088test: debug
Josh Coalson0cf199f2001-01-19 22:34:26 +000089 (cd test ; $(MAKE) -f Makefile.lite)
Josh Coalsonbb7f6b92000-12-10 04:09:52 +000090
91clean:
Josh Coalsonef5c2f82002-07-24 06:13:41 +000092 -(cd doc ; $(MAKE) -f Makefile.lite clean)
Josh Coalson0cf199f2001-01-19 22:34:26 +000093 -(cd src/libFLAC ; $(MAKE) -f Makefile.lite clean)
Josh Coalsonaae225a2002-05-17 06:07:26 +000094 -(cd src/libFLAC++ ; $(MAKE) -f Makefile.lite clean)
Josh Coalsonc49380d2002-08-07 17:38:08 +000095 -(cd src/libOggFLAC ; $(MAKE) -f Makefile.lite clean)
96 -(cd src/libOggFLAC++ ; $(MAKE) -f Makefile.lite clean)
Josh Coalsonaae225a2002-05-17 06:07:26 +000097 -(cd src/share ; $(MAKE) -f Makefile.lite clean)
Josh Coalson0cf199f2001-01-19 22:34:26 +000098 -(cd src/flac ; $(MAKE) -f Makefile.lite clean)
Josh Coalson74766922001-02-23 23:15:00 +000099 -(cd src/metaflac ; $(MAKE) -f Makefile.lite clean)
Josh Coalson1f99eac2002-08-23 06:45:23 +0000100 -(cd src/plugin_common ; $(MAKE) -f Makefile.lite clean)
Josh Coalson0cf199f2001-01-19 22:34:26 +0000101 -(cd src/plugin_xmms ; $(MAKE) -f Makefile.lite clean)
Josh Coalson57ba6f42002-06-07 05:27:37 +0000102 -(cd src/test_libFLAC ; $(MAKE) -f Makefile.lite clean)
103 -(cd src/test_libFLAC++ ; $(MAKE) -f Makefile.lite clean)
Josh Coalsona86f8702002-08-20 04:03:24 +0000104 -(cd src/test_libOggFLAC ; $(MAKE) -f Makefile.lite clean)
105 -(cd src/test_libOggFLAC++ ; $(MAKE) -f Makefile.lite clean)
Josh Coalson0cf199f2001-01-19 22:34:26 +0000106 -(cd src/test_streams ; $(MAKE) -f Makefile.lite clean)
Josh Coalson0cf199f2001-01-19 22:34:26 +0000107 -(cd test ; $(MAKE) -f Makefile.lite clean)