2015-06-14 17:43:40 +00:00
|
|
|
#
|
|
|
|
# Copyright (C) 2010-2014 OpenWrt.org
|
2017-05-05 23:05:56 +00:00
|
|
|
# Copyright (C) 2016-2017 Luiz Angelo Daros de Luca <luizluca@gmail.com>
|
2015-06-14 17:43:40 +00:00
|
|
|
#
|
|
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
|
|
# See /LICENSE for more information.
|
|
|
|
#
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=elfutils
|
2017-05-05 23:05:56 +00:00
|
|
|
PKG_VERSION:=0.169
|
2015-06-14 17:43:40 +00:00
|
|
|
PKG_RELEASE:=1
|
|
|
|
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
2016-12-29 03:53:45 +00:00
|
|
|
PKG_SOURCE_URL:=https://sourceware.org/$(PKG_NAME)/ftp/$(PKG_VERSION)
|
2017-05-05 23:05:56 +00:00
|
|
|
PKG_HASH:=9412fac7b30872b738bc1ed1ebcaed54493c26ef9a67887913498c17b10f3bc2
|
2015-06-14 17:43:40 +00:00
|
|
|
PKG_MAINTAINER:=Luiz Angelo Daros de Luca <luizluca@gmail.com>
|
|
|
|
PKG_LICENSE:=GPL-3.0+
|
|
|
|
PKG_LICENSE_FILES:=COPYING COPYING-GPLV2 COPYING-LGPLV3
|
|
|
|
|
|
|
|
PKG_INSTALL:=1
|
|
|
|
PKG_USE_MIPS16:=0
|
|
|
|
|
|
|
|
PKG_BUILD_DEPENDS:=USE_UCLIBC:argp-standalone USE_MUSL:argp-standalone
|
|
|
|
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
|
|
include $(INCLUDE_DIR)/nls.mk
|
|
|
|
|
|
|
|
define Package/elfutils/Default
|
|
|
|
SECTION:=libs
|
|
|
|
CATEGORY:=Libraries
|
|
|
|
TITLE:=ELF manipulation libraries
|
|
|
|
URL:=https://fedorahosted.org/elfutils/
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/libasm
|
|
|
|
$(call Package/elfutils/Default)
|
|
|
|
TITLE+= (libasm)
|
2016-10-14 00:02:47 +00:00
|
|
|
DEPENDS:=libelf1 +libdw
|
2015-06-14 17:43:40 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/libdw
|
|
|
|
$(call Package/elfutils/Default)
|
2016-01-20 13:54:13 +00:00
|
|
|
DEPENDS:=libelf1 +libbz2
|
2015-06-14 17:43:40 +00:00
|
|
|
TITLE+= (libdw)
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/libelf1
|
|
|
|
$(call Package/elfutils/Default)
|
2016-01-20 13:54:13 +00:00
|
|
|
DEPENDS:=$(INTL_DEPENDS) +zlib
|
2015-06-14 17:43:40 +00:00
|
|
|
TITLE+= (libelf)
|
|
|
|
endef
|
|
|
|
|
|
|
|
ifeq ($(CONFIG_BUILD_NLS),y)
|
|
|
|
TARGET_LDFLAGS += "-lintl"
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifdef CONFIG_USE_UCLIBC
|
|
|
|
CONFIGURE_VARS += \
|
|
|
|
LIBS="-largp"
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifdef CONFIG_USE_MUSL
|
|
|
|
CONFIGURE_VARS += \
|
|
|
|
LIBS="-largp"
|
|
|
|
endif
|
|
|
|
|
|
|
|
CONFIGURE_ARGS += \
|
|
|
|
--without-lzma
|
|
|
|
|
2016-12-29 03:53:45 +00:00
|
|
|
TARGET_CFLAGS += -D_GNU_SOURCE
|
|
|
|
|
2015-06-14 17:43:40 +00:00
|
|
|
define Build/InstallDev
|
|
|
|
$(INSTALL_DIR) $(1)/usr/include
|
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include/
|
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
|
|
|
$(CP) $(PKG_BUILD_DIR)/libasm/libasm.{a,so*} $(1)/usr/lib/
|
|
|
|
$(CP) $(PKG_BUILD_DIR)/libdw/libdw.{a,so*} $(1)/usr/lib/
|
|
|
|
$(CP) $(PKG_BUILD_DIR)/libelf/libelf.{a,so*} $(1)/usr/lib/
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/libasm/install
|
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
|
|
|
$(CP) $(PKG_BUILD_DIR)/libasm/libasm.so* $(1)/usr/lib/
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/libdw/install
|
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
|
|
|
$(CP) $(PKG_BUILD_DIR)/libdw/libdw.so* $(1)/usr/lib/
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/libelf1/install
|
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
|
|
|
$(CP) $(PKG_BUILD_DIR)/libelf/libelf.so* $(1)/usr/lib/
|
|
|
|
endef
|
|
|
|
|
|
|
|
$(eval $(call BuildPackage,libasm))
|
|
|
|
$(eval $(call BuildPackage,libdw))
|
|
|
|
$(eval $(call BuildPackage,libelf1))
|