369N/A# The contents of this file are subject to the terms of the
369N/A# Common Development and Distribution License (the "License").
369N/A# You may not use this file except in compliance with the License.
369N/A# See the License for the specific language governing permissions
369N/A# and limitations under the License.
369N/A# When distributing Covered Code, include this CDDL HEADER in each
369N/A# If applicable, add the following below this CDDL HEADER, with the
369N/A# fields enclosed by brackets "[]" replaced with your own identifying
369N/A# information: Portions Copyright [yyyy] [name of copyright owner]
4994N/A# Copyright (c) 2011, 2015, Oracle
and/or its affiliates. All rights reserved.
369N/A# Since we are building these as a set and not packaging them individually at
369N/A# this time, each OFED component should install in a common prototype directory
369N/A# so we override PROTO_DIR
369N/A# OFED only builds with GCC
2238N/Aifeq ($(strip $(PARFAIT_BUILD)),yes)
369N/ACPPFLAGS += "-Wformat=2"
369N/A# Since we are not currently packaging the various OFED components separately
369N/A# and we still need headers and to link with the components that we are
369N/A# building, we need to point the compiler and linker at a common proto area
369N/A# for OFED component headers and libraries.
369N/A# We need to insert the shared "proto" area include directories at the front
369N/A# of any compile line to preempt the system headers. It seems that the "best"
369N/A# way to do this is to augment the C/C++ compiler macros. YUCK!!!!
369N/ACC += $(SHARED_INCLUDES)
369N/ACXX += $(SHARED_INCLUDES)
369N/A# This is generally required, but must be overridable
369N/ADISABLE_LIBCHECK = --disable-libcheck
369N/ACONFIGURE_ENV += CFLAGS="$(CFLAGS)"
369N/ACONFIGURE_ENV += LD_OPTIONS="-R$(PROTO_DIR)/$(CONFIGURE_LIBDIR.$(BITS))"
369N/ACOMPONENT_INSTALL_ENV += LDFLAGS="-L$(PROTO_DIR)/$(CONFIGURE_LIBDIR.$(BITS))"
369N/ACOMPONENT_BUILD_ENV += CPPFLAGS="$(CPPFLAGS)"
369N/ACOMPONENT_BUILD_ENV += LIBS="$(LIBS)"
369N/ACOMPONENT_BUILD_ENV += LDFLAGS="-L$(PROTO_DIR)/$(CONFIGURE_LIBDIR.$(BITS)) $(LIBS)"
369N/ACOMPONENT_BUILD_ARGS += LDFLAGS="-L$(PROTO_DIR)/$(CONFIGURE_LIBDIR.$(BITS)) $(LIBS)"
369N/ACONFIGURE_OPTIONS += --disable-static
369N/ACONFIGURE_OPTIONS += $(DISABLE_LIBCHECK)
369N/ACLEAN_PATHS += $(BUILD_DIR)