You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

55 lines
1.3 KiB

  1. #
  2. # Copyright (C) 2007-2014 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. include $(INCLUDE_DIR)/kernel.mk
  9. PKG_NAME:=lsof
  10. PKG_VERSION:=4.86
  11. PKG_RELEASE:=2
  12. PKG_SOURCE:=$(PKG_NAME)_$(PKG_VERSION)+dfsg.orig.tar.gz
  13. PKG_SOURCE_URL:=http://ftp2.de.debian.org/debian/pool/main/l/lsof
  14. PKG_MD5SUM:=23420509564a897b76055f9d84d19068
  15. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)+dfsg.orig
  16. PKG_MAINTAINER:=Maxim Storchak <m.storchak@gmail.com>
  17. include $(INCLUDE_DIR)/package.mk
  18. TARGET_LDFLAGS += $(LIBRPC)
  19. define Package/lsof
  20. SECTION:=utils
  21. CATEGORY:=Utilities
  22. DEPENDS:=$(LIBRPC_DEPENDS)
  23. TITLE:=LiSt Open Files - a diagnostic tool
  24. URL:=http://people.freebsd.org/~abe/
  25. endef
  26. define Build/Configure
  27. cd $(PKG_BUILD_DIR); \
  28. LINUX_CLIB="-DGLIBCV=2" \
  29. LSOF_CC="$(TARGET_CC)" \
  30. LSOF_INCLUDE="-I$(STAGING_DIR)/usr/include" \
  31. LSOF_VSTR="$(LINUX_VERSION)" \
  32. LSOF_CFGF="$(TARGET_CFLAGS)" \
  33. LSOF_CFGL="$(TARGET_LDFLAGS)" \
  34. LSOF_AR="$(TARGET_CROSS)ar cr" \
  35. LSOF_RANLIB="$(TARGET_CROSS)ranlib" \
  36. ./Configure -n linux
  37. endef
  38. define Build/Compile
  39. $(MAKE) -C $(PKG_BUILD_DIR)
  40. endef
  41. define Package/lsof/install
  42. $(INSTALL_DIR) $(1)/usr/bin
  43. $(INSTALL_BIN) $(PKG_BUILD_DIR)/lsof $(1)/usr/bin
  44. endef
  45. $(eval $(call BuildPackage,lsof))