~ubuntu-branches/debian/stretch/clalsadrv/stretch

« back to all changes in this revision

Viewing changes to Makefile

  • Committer: Bazaar Package Importer
  • Author(s): Alessio Treglia
  • Date: 2010-04-17 12:25:13 UTC
  • mfrom: (1.1.4 upstream) (2.1.4 experimental)
  • Revision ID: james.westby@ubuntu.com-20100417122513-vsy32s4vwo8vgzvs
Tags: 2.0.0-2
Upload to unstable.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#  Copyright (C) 2003-2006 Fons Adriaensen <fons.adriaensen@skynet.be>
2
 
#
3
 
#  This program is free software; you can redistribute it and/or modify
4
 
#  it under the terms of the GNU General Public License as published by
5
 
#  the Free Software Foundation; either version 2 of the License, or
6
 
#  (at your option) any later version.
7
 
#
8
 
#  This program is distributed in the hope that it will be useful,
9
 
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
10
 
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11
 
#  GNU General Public License for more details.
12
 
 
13
 
#  You should have received a copy of the GNU General Public License
14
 
#  along with this program; if not, write to the Free Software
15
 
#  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
16
 
 
17
 
 
18
 
# Modify as required.
19
 
#
20
 
PREFIX = /usr
21
 
SUFFIX := $(shell uname -m | sed -e 's/^unknown/$//' -e 's/^i.86/$//' -e 's/^x86_64/$/64/')
22
 
LIBDIR = lib$(SUFFIX)
23
 
 
24
 
 
25
 
MAJVERS = 1
26
 
MINVERS = 2.2
27
 
VERSION = $(MAJVERS).$(MINVERS)
28
 
DISTDIR = clalsadrv-$(VERSION)
29
 
 
30
 
 
31
 
CPPFLAGS += -Wall -I. -fpic -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -O2 
32
 
LDLFAGS +=
33
 
LDLIBS += -lclalsadrv -lclthreads -lrt 
34
 
 
35
 
 
36
 
CLALSADRV_SO = libclalsadrv.so
37
 
CLALSADRV_MAJ = $(CLALSADRV_SO).$(MAJVERS)
38
 
CLALSADRV_MIN = $(CLALSADRV_MAJ).$(MINVERS)
39
 
CLALSADRV_DEP = -lasound
40
 
CLALSADRV_O = clalsadrv.o
41
 
CLALSADRV_H = clalsadrv.h
42
 
 
43
 
 
44
 
$(CLALSADRV_MIN): $(CLALSADRV_O)
45
 
        g++ -shared $(LDFLAGS) -Wl,-soname,$(CLALSADRV_MAJ) -o $(CLALSADRV_MIN) $(CLALSADRV_O) $(CLALSADRV_DEP)
46
 
 
47
 
 
48
 
install:        $(CLALSADRV_MIN)
49
 
        /usr/bin/install -d $(PREFIX)/$(LIBDIR)
50
 
        /usr/bin/install -m 644 $(CLALSADRV_H) $(PREFIX)/include
51
 
        /usr/bin/install -m 755 $(CLALSADRV_MIN) $(PREFIX)/$(LIBDIR)
52
 
        /sbin/ldconfig -n $(PREFIX)/$(LIBDIR)
53
 
        ln -sf $(CLALSADRV_MIN) $(PREFIX)/$(LIBDIR)/$(CLALSADRV_SO)
54
 
 
55
 
 
56
 
clean:
57
 
        /bin/rm -f *~ *.o *.a *.d *.so.* loopback
58
 
 
59
 
 
60
 
tarball:
61
 
        cd ..; \
62
 
        /bin/rm -f -r $(DISTDIR)*; \
63
 
        svn export clalsadrv $(DISTDIR); \
64
 
        tar cvf $(DISTDIR).tar $(DISTDIR); \
65
 
        bzip2 $(DISTDIR).tar; \
66
 
        /bin/rm -f -r $(DISTDIR);
67