1################################################################################ 2# 3# oprofile 4# 5################################################################################ 6 7OPROFILE_VERSION = 1.4.0 8OPROFILE_SITE = http://downloads.sourceforge.net/project/oprofile/oprofile/oprofile-$(OPROFILE_VERSION) 9OPROFILE_LICENSE = GPL-2.0+ 10OPROFILE_LICENSE_FILES = COPYING 11OPROFILE_CPE_ID_VENDOR = maynard_johnson 12OPROFILE_CONF_OPTS = \ 13 --disable-account-check \ 14 --enable-gui=no \ 15 --with-kernel=$(STAGING_DIR)/usr 16 17OPROFILE_BINARIES = \ 18 utils/ophelp pp/opannotate pp/oparchive pp/opgprof \ 19 pp/opreport opjitconv/opjitconv \ 20 utils/op-check-perfevents libabi/opimport \ 21 pe_counting/ocount pe_profiling/operf 22 23ifeq ($(BR2_i386),y) 24OPROFILE_ARCH = i386 25endif 26ifeq ($(BR2_mipsel),y) 27OPROFILE_ARCH = mips 28endif 29ifeq ($(BR2_powerpc),y) 30OPROFILE_ARCH = ppc 31endif 32ifeq ($(BR2_x86_64),y) 33OPROFILE_ARCH = x86-64 34endif 35ifeq ($(OPROFILE_ARCH),) 36OPROFILE_ARCH = $(BR2_ARCH) 37endif 38 39OPROFILE_DEPENDENCIES = popt binutils host-pkgconf 40 41ifeq ($(BR2_PACKAGE_LIBPFM4),y) 42OPROFILE_DEPENDENCIES += libpfm4 43endif 44 45ifeq ($(BR2_STATIC_LIBS),) 46define OPROFILE_INSTALL_SHARED_LIBRARY 47 $(INSTALL) -m 755 $(@D)/libopagent/.libs/*.so* $(TARGET_DIR)/usr/lib/oprofile 48endef 49endif 50 51define OPROFILE_INSTALL_TARGET_CMDS 52 $(INSTALL) -d -m 755 $(TARGET_DIR)/usr/bin 53 $(INSTALL) -d -m 755 $(TARGET_DIR)/usr/share/oprofile 54 $(INSTALL) -d -m 755 $(TARGET_DIR)/usr/lib/oprofile 55 if [ -d $(@D)/events/$(OPROFILE_ARCH) ]; then \ 56 cp -dpfr $(@D)/events/$(OPROFILE_ARCH) \ 57 $(TARGET_DIR)/usr/share/oprofile; \ 58 fi 59 $(INSTALL) -m 644 $(@D)/libregex/stl.pat $(TARGET_DIR)/usr/share/oprofile 60 $(INSTALL) -m 755 $(addprefix $(@D)/, $(OPROFILE_BINARIES)) $(TARGET_DIR)/usr/bin 61 $(OPROFILE_INSTALL_SHARED_LIBRARY) 62endef 63 64$(eval $(autotools-package)) 65