source: packages/utils/smartmontools/Makefile @ 28326

Last change on this file since 28326 was 28326, checked in by florian, 5 years ago

[package] smartmontools: split daemon into its own package

Based on a patch by Eugene San.

  • Property copyright set to Copyright (C) 2006 OpenWrt.org
  • Property svn:eol-style set to native
File size: 2.3 KB
Line 
1#
2# Copyright (C) 2006-2011 OpenWrt.org
3#
4# This is free software, licensed under the GNU General Public License v2.
5# See /LICENSE for more information.
6#
7
8include $(TOPDIR)/rules.mk
9
10PKG_NAME:=smartmontools
11PKG_VERSION:=5.40
12PKG_RELEASE:=1
13
14PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15PKG_SOURCE_URL:=@SF/smartmontools
16PKG_MD5SUM:=0f0be0239914ad87830a4fff594bda5b
17
18include $(INCLUDE_DIR)/package.mk
19
20define Package/smartmontools/Default
21  SECTION:=utils
22  CATEGORY:=Utilities
23  DEPENDS:=+uclibcxx
24  TITLE:=S.M.A.R.T Monitoring
25  URL:=http://smartmontools.sourceforge.net/
26endef
27
28define Package/smartmontools
29  $(call Package/smartmontools/Default)
30  TITLE+= Tool
31endef
32
33define Package/smartmontools/description
34  smartmontools contains utility programs (smartctl) to
35  control/monitor storage systems using the Self-Monitoring, Analysis
36  and Reporting Technology System (S.M.A.R.T.) built into most modern
37  ATA and SCSI disks. It is derived from smartsuite.
38endef
39
40define Package/smartd
41  $(call Package/smartmontools/Default)
42  DEPENDS+= +rsync
43  TITLE+= Daemon
44endef
45
46define Package/smartd/description
47  smartmontools contains utility programs (smartd) to
48  control/monitor storage systems using the Self-Monitoring, Analysis
49  and Reporting Technology System (S.M.A.R.T.) built into most modern
50  ATA and SCSI disks. It is derived from smartsuite.
51endef
52
53# uses GNU configure
54
55CONFIGURE_VARS += \
56        CXXFLAGS="$$$$CXXFLAGS -fno-builtin -fno-rtti -nostdinc++" \
57        CPPFLAGS="$$$$CPPFLAGS -I$(STAGING_DIR)/usr/include/uClibc++ -I$(LINUX_DIR)/include" \
58        LDFLAGS="$$$$LDFLAGS" \
59        LIBS="-nodefaultlibs -luClibc++ -lm $(LIBGCC_S) -lc" \
60
61define Build/Configure
62        (cd $(PKG_BUILD_DIR); rm -rf config.{cache,status} ; \
63                ./autogen.sh \
64        );
65        $(call Build/Configure/Default)
66endef
67
68define Build/Compile
69        $(MAKE) -C $(PKG_BUILD_DIR) \
70                LD="$(TARGET_CXX)"
71endef
72
73define Package/smartmontools/install
74        $(INSTALL_DIR) $(1)/usr/sbin
75        $(INSTALL_BIN) $(PKG_BUILD_DIR)/smartctl $(1)/usr/sbin/
76endef
77
78define Package/smartd/install
79        $(INSTALL_DIR) $(1)/usr/sbin
80        $(INSTALL_BIN) $(PKG_BUILD_DIR)/smartd $(1)/usr/sbin/
81        $(INSTALL_DIR) $(1)/etc
82        $(INSTALL_DATA) ./files/smartd.conf $(1)/etc/
83        $(INSTALL_DIR) $(1)/etc/init.d
84        $(INSTALL_BIN) ./files/smartd.init $(1)/etc/init.d/smartd
85endef
86
87$(eval $(call BuildPackage,smartmontools))
88$(eval $(call BuildPackage,smartd))
Note: See TracBrowser for help on using the repository browser.