2 # Copyright (C) 2009-2010 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
:=@SF
/oprofile
/
16 PKG_MD5SUM
:=82b059379895cf125261d7d773465915
18 PKG_BUILD_DEPENDS
:=binutils
22 include $(INCLUDE_DIR
)/package.mk
23 include $(INCLUDE_DIR
)/kernel.mk
25 define KernelPackage
/oprofile
26 SUBMENU
:=Other modules
27 TITLE
:=OProfile profiling support
28 KCONFIG
:=CONFIG_OPROFILE @LINUX_2_6
29 FILES
:=$(LINUX_DIR
)/arch
/$(LINUX_KARCH
)/oprofile
/oprofile.
$(LINUX_KMOD_SUFFIX
)
30 DEPENDS
:=@KERNEL_PROFILING
33 define KernelPackage
/oprofile
/description
34 Kernel module for support for oprofile system profiling.
37 define Package
/oprofile
40 TITLE
:=OProfile System Profiler
41 URL
:=http
://oprofile.sourceforge.net
42 DEPENDS
:=+libpopt
+kmod-oprofile
+libstdcpp
+objdump
45 define Package
/oprofile
/description
46 A transparent low-overhead system-wide profiler.
49 define Build
/Configure
50 $(call Build
/Configure
/Default
, \
51 --with-kernel-support \
56 TARGET_LDFLAGS
:= -L
$(STAGING_DIR
)/usr
/lib
$(TARGET_LDFLAGS
)
58 define Package
/oprofile
/install
59 $(INSTALL_DIR
) $(1)/usr
/bin
61 $(PKG_INSTALL_DIR
)/usr
/bin
/* \
64 $(INSTALL_DIR
) $(1)/usr
/lib
/oprofile
66 $(PKG_INSTALL_DIR
)/usr
/lib
/oprofile
/*.so
* \
67 $(1)/usr
/lib
/oprofile
/
69 $(INSTALL_DIR
) $(1)/usr
/share
/oprofile
71 $(PKG_INSTALL_DIR
)/usr
/share
/oprofile
/stl.pat \
72 $(PKG_INSTALL_DIR
)/usr
/share
/oprofile
/$(LINUX_KARCH
) \
73 $(1)/usr
/share
/oprofile
/
76 $(eval
$(call BuildPackage
,oprofile
))
77 $(eval
$(call KernelPackage
,oprofile
))