da2099e72d8814901fc12a7020fb3a3708a85322
[openwrt/svn-archive/archive.git] / utils / sane-backends / Makefile
1 #
2 # Copyright (C) 2006 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=sane-backends
12 PKG_VERSION:=1.0.17
13 PKG_RELEASE:=1
14 PKG_MD5SUM:=b51c10da8a81a04e1bae88c9e6556df2
15
16 PKG_SOURCE_URL:=ftp://ftp.sane-project.org/pub/sane/$(PKG_NAME)-$(PKG_VERSION)/
17 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
18 PKG_CAT:=zcat
19
20 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
21 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/sane-backends
26 SECTION:=utils
27 CATEGORY:=Utilities
28 TITLE:=Scanner Access Now Easy (backends)
29 DESCRIPTION:=SANE (Scanner Access Now Easy) is a universal scanner interface.
30 URL:=http://www.sane-project.org
31 endef
32
33 define Package/sane-backends/conffiles
34 /etc/sane.d/saned.conf
35 endef
36
37 define Build/Configure
38 $(call Build/Configure/Default,--enable-shared \
39 --disable-static \
40 --disable-ipv6 \
41 --disable-translations \
42 --without-gphoto2 \
43 --disable-debug)
44 endef
45
46 define Build/Compile
47 $(MAKE) -C $(PKG_BUILD_DIR)
48 mkdir -p $(PKG_INSTALL_DIR)
49 $(MAKE) -C $(PKG_BUILD_DIR) \
50 DESTDIR="$(PKG_INSTALL_DIR)" \
51 install
52 endef
53
54 define Package/sane-backends/install
55 install -d -m0755 $(1)/etc/sane.d
56 $(CP) $(PKG_INSTALL_DIR)/etc/sane.d/*.conf $(1)/etc/sane.d/
57 install -d -m0755 $(1)/usr/sbin
58 $(CP) $(PKG_INSTALL_DIR)/usr/sbin/saned $(1)/usr/sbin/
59 endef
60
61 $(eval $(call BuildPackage,sane-backends))