Makefile revision 6302
d6fa26d0adaec6c910115be34fe7a5a5f402c14fMark Andrews#
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# CDDL HEADER START
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User#
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# The contents of this file are subject to the terms of the
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User# Common Development and Distribution License (the "License").
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User# You may not use this file except in compliance with the License.
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox User#
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
d6fa26d0adaec6c910115be34fe7a5a5f402c14fMark Andrews# or http://www.opensolaris.org/os/licensing.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# See the License for the specific language governing permissions
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# and limitations under the License.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein#
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User# When distributing Covered Code, include this CDDL HEADER in each
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# If applicable, add the following below this CDDL HEADER, with the
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# fields enclosed by brackets "[]" replaced with your own identifying
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# information: Portions Copyright [yyyy] [name of copyright owner]
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein#
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# CDDL HEADER END
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein#
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein#
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Copyright (c) 2012, 2016, Oracle and/or its affiliates. All rights reserved.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein#
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinBUILD_BITS= 64
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPILER= gcc
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austeininclude ../../make-rules/shared-macros.mk
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_NAME= rsyslog
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserCOMPONENT_VERSION= 8.15.0
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_PROJECT_URL= http://www.rsyslog.com/
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_ARCHIVE_HASH= sha256:9ed6615a8503964290471e98ed363f3975b964a34c2d4610fb815a432aadaf59
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_ARCHIVE_URL= $(COMPONENT_PROJECT_URL)files/download/$(COMPONENT_NAME)/$(COMPONENT_ARCHIVE)
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserCOMPONENT_BUGDB= service/rsyslog
c2258eedf2d9d0207b45b90014f8fde5413b41a3Tinderbox User
5347c0fcb04eaea19d9f39795646239f487c6207Tinderbox UserTPNO= 28284
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# The documentation is in a separate download
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_SRC_DOC= $(COMPONENT_NAME)-doc-$(COMPONENT_VERSION)
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_ARCHIVE_DOC= $(COMPONENT_SRC_DOC).tar.gz
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_ARCHIVE_HASH_DOC= sha256:3462402165a3ff34ceff23db20382a14bd3727131994f140a004f4872a01c12a
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserCOMPONENT_ARCHIVE_URL_DOC= $(COMPONENT_PROJECT_URL)files/download/$(COMPONENT_NAME)/$(COMPONENT_ARCHIVE_DOC)
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinUNPACK_ARGS_DOC= -r $(COMPONENT_SRC_DOC)
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# There are tests, but gmake test is currently broken.
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# It was working in the previous version, but not sure why
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# it breaks now. Leaving it at no tests for now.
010a51c427bfb6ab658fc0056955a1a5b69810beTinderbox UserTEST_TARGET= $(NO_TESTS)
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox Userinclude $(WS_MAKE_RULES)/common.mk
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# Automake fix, regenerates configure file to get rid of the
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# automake 'probably too old' error. This fixes gmake test
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# needing more than one try to run. This does not fix the
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# fact that gmake test runs no tests.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_PRE_CONFIGURE_ACTION= cd $(SOURCE_DIR); \
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein aclocal; \
71c66a876ecca77923638d3f94cc0783152b2f03Mark Andrews autoconf; \
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein automake -a;
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# gmake test will generate different outputs if run multiple
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# times. This gets rid of all the unimportant output
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox UserCOMPONENT_TEST_TRANSFORMS += '-e "/\(CC\).*/d" '
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox UserCOMPONENT_TEST_TRANSFORMS += '-e "/\(make\).*/d" '
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_TEST_TRANSFORMS += '-e "/\(source\).*/d" '
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_TEST_TRANSFORMS += '-e "/\(check\).*/d" '
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCOMPONENT_TEST_TRANSFORMS += '-e "/\(usr\).*/d" '
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntCOMPONENT_TEST_TRANSFORMS += '-e "/\(SOURCE_DIR\).*/d" '
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# This is needed for things to be built correctly.
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox UserCFLAGS += -std=c99
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# A normal 64-bit build would result in /usr/lib/$(MACH64)/rsyslog but since we
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# have a self-contained eco-system, simplify things for customers and just use
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# /usr/lib/rsyslog .
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox UserCONFIGURE_LIBDIR.64 = $(CONFIGURE_LIBDIR.32)
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# Rsyslog sources contain __FILE__ macros which contain full path to the workspace
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# This may appear in debug output which is not nice. By specifying the source
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# path relative we force the macro to be relative path too.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCONFIGURE_OPTIONS += --srcdir=../../$(COMPONENT_NAME)-$(COMPONENT_VERSION)
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntCONFIGURE_OPTIONS += --enable-imsolaris
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntCONFIGURE_OPTIONS += --enable-mail
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntCONFIGURE_OPTIONS += --enable-gssapi_krb5
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntCONFIGURE_OPTIONS += --enable-gnutls
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox UserCONFIGURE_OPTIONS += --disable-klog
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox UserCONFIGURE_OPTIONS += --sbindir=$(USRLIBDIR)/rsyslog
14a656f94b1fd0ababd84a772228dfa52276ba15Evan Hunt
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein# libgcrypt is not approved.
2b4d1b54f6ca406b8233d9e6fea9593df6dad035Tinderbox UserCONFIGURE_OPTIONS += --disable-libgcrypt
2b4d1b54f6ca406b8233d9e6fea9593df6dad035Tinderbox UserCONFIGURE_OPTIONS += --enable-extended-tests
2b4d1b54f6ca406b8233d9e6fea9593df6dad035Tinderbox User
2b4d1b54f6ca406b8233d9e6fea9593df6dad035Tinderbox User# There are man pages in the tarball, which will require modification for
2b4d1b54f6ca406b8233d9e6fea9593df6dad035Tinderbox User# content. Also, building them from here requires python-docutils.
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob AusteinCONFIGURE_OPTIONS += --disable-generate-man-pages
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# Make the build verbose, show executed commands
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntCOMPONENT_BUILD_ARGS += AM_DEFAULT_VERBOSITY=1
60e5e10f8d2e2b0c41e8abad38cacd867caa6ab2Rob Austein
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# common targets
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox UserPROTODOCDIR= $(PROTOUSRSHAREDOCDIR)/$(COMPONENT_NAME)
af40ebed6257e4ac1996144530b3de317cf4da11Tinderbox User# Docs to install are the tree under docs/build with some exceptions.
44d0f0256fbdce130a18655023c3b06bacacbd61Automatic Updater
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntCOMPONENT_POST_INSTALL_ACTION += \
6f64d4ab8e68f9b2333bcbfc755396d29a4a9d7cAutomatic Updater ($(MKDIR) $(PROTODOCDIR) ; \
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User cd $(COMPONENT_SRC_DOC)/build ; \
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User find . \( -name '_sources' \
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User -o -name '.doctrees' \
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User -o -name '.buildinfo' \
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User -o -name 'objects.inv' \) \
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User -prune -o -print0 \
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User | cpio -pd0u $(PROTODOCDIR))
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserREQUIRED_PACKAGES += library/gnutls
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserREQUIRED_PACKAGES += library/json-c
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserREQUIRED_PACKAGES += library/libestr
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserREQUIRED_PACKAGES += library/liblogging
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox UserREQUIRED_PACKAGES += library/zlib
6f64d4ab8e68f9b2333bcbfc755396d29a4a9d7cAutomatic UpdaterREQUIRED_PACKAGES += security/kerberos-5
14a656f94b1fd0ababd84a772228dfa52276ba15Evan HuntREQUIRED_PACKAGES += shell/ksh93
44d0f0256fbdce130a18655023c3b06bacacbd61Automatic UpdaterREQUIRED_PACKAGES += system/core-os
fd2597f75693a2279fdf588bd40dfe2407c42028Tinderbox User