1487N/A#
1487N/A# CDDL HEADER START
1487N/A#
1487N/A# The contents of this file are subject to the terms of the
1487N/A# Common Development and Distribution License (the "License").
1487N/A# You may not use this file except in compliance with the License.
1487N/A#
1487N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
1487N/A# or http://www.opensolaris.org/os/licensing.
1487N/A# See the License for the specific language governing permissions
1487N/A# and limitations under the License.
1487N/A#
1487N/A# When distributing Covered Code, include this CDDL HEADER in each
1487N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
1487N/A# If applicable, add the following below this CDDL HEADER, with the
1487N/A# fields enclosed by brackets "[]" replaced with your own identifying
1487N/A# information: Portions Copyright [yyyy] [name of copyright owner]
1487N/A#
1487N/A# CDDL HEADER END
1487N/A#
5680N/A
5680N/A#
5348N/A# Copyright (c) 2013, 2016, Oracle and/or its affiliates. All rights reserved.
1487N/A#
1487N/A
3109N/AVENDOR_RUBY = /usr/ruby/$(RUBY_VERSION)/lib/ruby/vendor_ruby/$(RUBY_LIB_VERSION)
1487N/A
5353N/A# install into proto area
5353N/AINSTALL_RB_DESTDIR_OPTION = --destdir=$(PROTO_DIR)
5353N/A# use correct version of Ruby rather than the one calling install.rb
5353N/AINSTALL_RB_RUBY_OPTION = --ruby=$(RUBY)
5353N/A# ensure the bin dir is not a
5353N/A# Ruby-version-specific directory
5353N/AINSTALL_RB_BINDIR_OPTION = --bindir=$(USRBINDIR)
5353N/A# install into vendor_ruby instead of site_ruby
5353N/AINSTALL_RB_SITELIBDIR_OPTION = --sitelibdir=$(VENDOR_RUBY)
5353N/A# install into standard man directory
5353N/AINSTALL_RB_MANDIR_OPTION = --mandir=$(USRSHAREMANDIR)
5353N/A# ensure the sbin dir is not a
5353N/A# Ruby-version-specific directory
5353N/AINSTALL_RB_SBINDIR_OPTION = --sbindir=$(USRSBINDIR)
5353N/A
5353N/AINSTALL_RB_OPTIONS += $(INSTALL_RB_DESTDIR_OPTION)
5353N/AINSTALL_RB_OPTIONS += $(INSTALL_RB_RUBY_OPTION)
5353N/AINSTALL_RB_OPTIONS += $(INSTALL_RB_BINDIR_OPTION)
5353N/AINSTALL_RB_OPTIONS += $(INSTALL_RB_SITELIBDIR_OPTION)
5353N/AINSTALL_RB_OPTIONS += $(INSTALL_RB_MANDIR_OPTION)
5353N/AINSTALL_RB_OPTIONS += $(INSTALL_RB_SBINDIR_OPTION)
1487N/A
1487N/A# install.rb scripts do not have any concept of 'build' so make this a
1487N/A# no-op
1487N/A$(BUILD_DIR)/%/.built: $(SOURCE_DIR)/.prep
1487N/A $(RM) -r $(@D) ; $(MKDIR) $(@D)
1487N/A $(COMPONENT_PRE_BUILD_ACTION)
1487N/A $(COMPONENT_POST_BUILD_ACTION)
1487N/A $(TOUCH) $@
1487N/A
1487N/A# install the source into the proto directory
1487N/A$(BUILD_DIR)/%/.installed: $(BUILD_DIR)/%/.built
1487N/A $(COMPONENT_PRE_INSTALL_ACTION)
1487N/A (cd $(SOURCE_DIR) ; $(ENV) $(COMPONENT_INSTALL_ENV) \
5353N/A ./install.rb $(INSTALL_RB_OPTIONS) )
1487N/A $(COMPONENT_POST_INSTALL_ACTION)
1487N/A $(TOUCH) $@
1487N/A
3817N/AREQUIRED_PACKAGES += runtime/ruby