2 # Copyright (C) 2007-2009 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR)/rules.mk
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://liboil.freedesktop.org/download/
16 PKG_MD5SUM:=11dd39b1ca13ce2e0618d4df8303f137
18 PKG_BUILD_DEPENDS:=libnotimpl
21 include $(INCLUDE_DIR)/package.mk
26 TITLE:=simple functions optimized for various CPUs
27 URL:=http://liboil.freedesktop.org/wiki/
30 define Package/liboil/description
31 Liboil is a library of simple functions that are optimized for various CPUs.
32 These functions are generally loops implementing simple algorithms, such as
33 converting an array of N integers to floating-point numbers or multiplying
34 and summing an array of N numbers. Such functions are candidates for significant
35 optimization using various techniques, especially by using extended instructions
36 provided by modern CPUs (Altivec, MMX, SSE, etc.).
39 TARGET_CFLAGS += $(FPIC)
45 # XXX: VFP_CFLAGS is set to '-mfpu=vfp' on arm by configure, but that breaks
46 # final linking stages, so override it until we find why
48 $(MAKE) -C $(PKG_BUILD_DIR) \
49 DESTDIR="$(PKG_INSTALL_DIR)" \
54 define Build/InstallDev
55 $(INSTALL_DIR) $(1)/usr/include
56 $(CP) $(PKG_INSTALL_DIR)/usr/include/liboil-0.3/* $(1)/usr/include/
57 $(INSTALL_DIR) $(1)/usr/lib
58 $(CP) $(PKG_INSTALL_DIR)/usr/lib/liboil-0.3.{a,so*} $(1)/usr/lib/
59 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
60 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/liboil-0.3.pc $(1)/usr/lib/pkgconfig/
63 define Package/liboil/install
64 $(INSTALL_DIR) $(1)/usr/lib
65 $(CP) $(PKG_INSTALL_DIR)/usr/lib/liboil-0.3.so.* $(1)/usr/lib/
68 $(eval $(call BuildPackage,liboil))