Makefile revision 3353
#
# CDDL HEADER START
#
# The contents of this file are subject to the terms of the
# Common Development and Distribution License (the "License").
# You may not use this file except in compliance with the License.
#
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
# or http://www.opensolaris.org/os/licensing.
# See the License for the specific language governing permissions
# and limitations under the License.
#
# When distributing Covered Code, include this CDDL HEADER in each
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
# If applicable, add the following below this CDDL HEADER, with the
# fields enclosed by brackets "[]" replaced with your own identifying
# information: Portions Copyright [yyyy] [name of copyright owner]
#
# CDDL HEADER END
#
#
# Copyright (c) 2013, 2014, Oracle and/or its affiliates. All rights reserved.
#
include ../../make-rules/shared-macros.mk
COMPONENT_NAME= smp_utils
COMPONENT_VERSION= 0.97
COMPONENT_PROJECT_URL= http://sg.danny.cz/sg/smp_utils.html
COMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
COMPONENT_ARCHIVE= $(COMPONENT_SRC).tgz
COMPONENT_ARCHIVE_HASH= \
sha256:0e10d304cfa8789bcf16537e8f72d9afdf8838fca20ae68103c317432d00915b
COMPONENT_ARCHIVE_URL= http://sg.danny.cz/sg/p/$(COMPONENT_ARCHIVE)
COMPONENT_BUGDB= utility/smputils
TPNO= 11065
include ../../make-rules/prep.mk
include ../../make-rules/configure.mk
include ../../make-rules/ips.mk
CC += $(CC_BITS)
LDFLAGS += $(CC_BITS)
COMPONENT_BUILD_ARGS += CC="$(CC)"
COMPONENT_BUILD_ARGS += LDFLAGS="$(LDFLAGS)"
CPPFLAGS += -I$(COMPONENT_DIR)/$(COMPONENT_SRC)/include
CONFIGURE_OPTIONS += --disable-static
CONFIGURE_OPTIONS += CPPFLAGS="$(CPPFLAGS)"
# Don't use rpath!
COMPONENT_POST_CONFIGURE_ACTION = \
(cd $(BUILD_DIR_64) ; \
$(GSED) -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool ; \
$(GSED) -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool)
# Move the section 8 man pages into section 1m.
COMPONENT_POST_INSTALL_ACTION = \
for f in $(PROTOUSRSHAREMANDIR)/man8/*; do \
mv $$f $${f%.8}.1m; \
done ; \
$(MV) $(PROTOUSRSHAREMANDIR)/man8 $(PROTOUSRSHAREMANDIR)/man1m
PKG_PROTO_DIRS += $(COMPONENT_DIR)/files
COMPONENT_INSTALL_ARGS += INSTALL=$(INSTALL)
COMPONENT_INSTALL_ARGS += INSTALL_TOP=$(PROTOUSRDIR)
$(INSTALL_64): COMPONENT_INSTALL_ARGS += INSTALL_LIB=$(PROTOUSRLIBDIR64)
$(INSTALL_64): COMPONENT_INSTALL_ARGS += INSTALL_SBIN=$(PROTOUSRBINDIR64)
COMPONENT_TEST_ENV += LD_LIBRARY_PATH=$(PROTOUSRLIBDIR64)
COMPONENT_TEST_CMD = \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_conf_general -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_conf_phy_event -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_conf_route_info -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_conf_zone_man_pass -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_conf_zone_perm_tbl -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_conf_zone_phy_info -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_discover -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_discover_list -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_ena_dis_zoning -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_phy_control -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_phy_test -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_read_gpio -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_broadcast -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_exp_route_tbl -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_general -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_manufacturer -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_phy_err_log -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_phy_event -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_phy_event_list -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_phy_sata -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_route_info -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_self_conf_stat -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_zone_man_pass -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_rep_zone_perm_tbl -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_write_gpio -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_zone_activate -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_zone_lock -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_zone_unlock -V; \
$(PROTOUSRDIR)/sbin/$(MACH64)/smp_zoned_broadcast -V
ASLR_MODE = $(ASLR_ENABLE)
# common targets
build: $(BUILD_64)
install: $(INSTALL_64)
test: install $(TEST_64)
BUILD_PKG_DEPENDENCIES = $(BUILD_TOOLS)
include ../../make-rules/depend.mk