disable mrd6, compile is broken
[openwrt.git] / openwrt / package / libvorbis / Makefile
1 # $Id$
2
3 include $(TOPDIR)/rules.mk
4
5 PKG_NAME:=libvorbis
6 PKG_VERSION:=1.1.2
7 PKG_RELEASE:=1
8 PKG_MD5SUM:=37847626b8e1b53ae79a34714c7b3211
9
10 PKG_SOURCE_URL:=http://downloads.xiph.org/releases/vorbis/
11 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
12 PKG_CAT:=zcat
13
14 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
15 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
16
17 include $(TOPDIR)/package/rules.mk
18
19 $(eval $(call PKG_template,LIBVORBIS,libvorbis,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
20
21 # NOTE: check ./toolchain/libnotimpl
22 # it implements those functions missing from the version of uClibc we're currently using
23 # for libvorbis, they are cosf/sinf
24
25 $(PKG_BUILD_DIR)/.configured:
26 (cd $(PKG_BUILD_DIR); rm -rf config.{cache,status} ; \
27 $(TARGET_CONFIGURE_OPTS) \
28 CFLAGS="$(strip $(TARGET_CFLAGS))" \
29 CPPFLAGS="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
30 LDFLAGS="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
31 LIBS="-lm -logg -lnotimpl" \
32 PKG_CONFIG_PATH="$(STAGING_DIR)/usr/lib/pkgconfig" \
33 ./configure \
34 --target=$(GNU_TARGET_NAME) \
35 --host=$(GNU_TARGET_NAME) \
36 --build=$(GNU_HOST_NAME) \
37 --program-prefix="" \
38 --program-suffix="" \
39 --prefix=/usr \
40 --exec-prefix=/usr \
41 --bindir=/usr/bin \
42 --datadir=/usr/share \
43 --includedir=/usr/include \
44 --infodir=/usr/share/info \
45 --libdir=/usr/lib \
46 --libexecdir=/usr/lib \
47 --localstatedir=/var \
48 --mandir=/usr/share/man \
49 --sbindir=/usr/sbin \
50 --sysconfdir=/etc \
51 $(DISABLE_LARGEFILE) \
52 $(DISABLE_NLS) \
53 --enable-shared \
54 --enable-static \
55 --disable-rpath \
56 --with-gnu-ld \
57 --with-ogg="$(STAGING_DIR)/usr" \
58 --with-ogg-includes="$(STAGING_DIR)/usr/include" \
59 --with-ogg-libraries="$(STAGING_DIR)/usr/lib" \
60 );
61 touch $@
62
63 $(PKG_BUILD_DIR)/.built:
64 rm -rf $(PKG_INSTALL_DIR)
65 mkdir -p $(PKG_INSTALL_DIR)
66 $(MAKE) -C $(PKG_BUILD_DIR) \
67 DESTDIR="$(PKG_INSTALL_DIR)" \
68 all install
69 touch $@
70
71 $(IPKG_LIBVORBIS):
72 install -m0755 -d $(IDIR_LIBVORBIS)/usr/lib
73 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libvorbis.so.* $(IDIR_LIBVORBIS)/usr/lib/
74 $(RSTRIP) $(IDIR_LIBVORBIS)
75 $(IPKG_BUILD) $(IDIR_LIBVORBIS) $(PACKAGE_DIR)
76
77 $(STAGING_DIR)/usr/lib/libvorbis.so: $(PKG_BUILD_DIR)/.built
78 mkdir -p $(STAGING_DIR)/usr/include
79 $(CP) $(PKG_INSTALL_DIR)/usr/include/vorbis $(STAGING_DIR)/usr/include/
80 mkdir -p $(STAGING_DIR)/usr/lib
81 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libvorbis.a $(STAGING_DIR)/usr/lib/
82 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libvorbis{,enc,file}.so* $(STAGING_DIR)/usr/lib/
83 mkdir -p $(STAGING_DIR)/usr/lib/pkgconfig
84 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/vorbis{,enc,file}.pc $(STAGING_DIR)/usr/lib/pkgconfig/
85 $(SED) 's,-I$${includedir},,g' $(STAGING_DIR)/usr/lib/pkgconfig/vorbis{,enc,file}.pc
86 $(SED) 's,-L$${libdir},,g' $(STAGING_DIR)/usr/lib/pkgconfig/vorbis{,enc,file}.pc
87 touch $@
88
89 install-dev: $(STAGING_DIR)/usr/lib/libvorbis.so
90
91 uninstall-dev:
92 rm -rf \
93 $(STAGING_DIR)/usr/include/vorbis \
94 $(STAGING_DIR)/usr/lib/libvorbis{,enc,file}.a \
95 $(STAGING_DIR)/usr/lib/libvorbis{,enc,file}.so* \
96 $(STAGING_DIR)/usr/lib/pkgconfig/vorbis{,enc,file}.pc \
97
98 compile-targets: install-dev
99 clean-targets: uninstall-dev
100
101 mostlyclean:
102 -$(MAKE) -C $(PKG_BUILD_DIR) clean
103 rm -f $(PKG_BUILD_DIR)/.built
104
This page took 0.045842 seconds and 5 git commands to generate.