Makefile revision 5398
5398N/A#
5398N/A# CDDL HEADER START
5398N/A#
5398N/A# The contents of this file are subject to the terms of the
5398N/A# Common Development and Distribution License (the "License").
5398N/A# You may not use this file except in compliance with the License.
5398N/A#
5398N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
5398N/A# or http://www.opensolaris.org/os/licensing.
5398N/A# See the License for the specific language governing permissions
5398N/A# and limitations under the License.
5398N/A#
5398N/A# When distributing Covered Code, include this CDDL HEADER in each
5398N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
5398N/A# If applicable, add the following below this CDDL HEADER, with the
5398N/A# fields enclosed by brackets "[]" replaced with your own identifying
5398N/A# information: Portions Copyright [yyyy] [name of copyright owner]
5398N/A#
5398N/A# CDDL HEADER END
5398N/A#
5398N/A
5398N/A#
5398N/A# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
5398N/A#
5398N/A
5398N/Ainclude ../../../make-rules/shared-macros.mk
5398N/A
5398N/ACOMPONENT_NAME= xscreensaver
5398N/ACOMPONENT_VERSION= 5.15
5398N/ACOMPONENT_PROJECT_URL= https://www.jwz.org/xscreensaver/
5398N/ACOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
5398N/ACOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.gz
5398N/ACOMPONENT_ARCHIVE_HASH= \
5398N/A sha256:4f6d1f1e4c15dbb74e2296f8fe57a73d47d602515178c248bbc838f779d5082d
5398N/A#COMPONENT_ARCHIVE_URL= https://www.jwz.org/xscreensaver/$(COMPONENT_ARCHIVE)
5398N/A# jwz removes older tarballs, and 5.15 is no longer on his site, so borrow
5398N/A# Fedora's archive until we update
5398N/ACOMPONENT_ARCHIVE_URL= http://pkgs.fedoraproject.org/repo/pkgs/xscreensaver/xscreensaver-5.15.tar.gz/c0b8b2c817a9a7371f51a82e80602d10/$(COMPONENT_ARCHIVE)
5398N/ACOMPONENT_BUGDB= gnome/screensaver
5398N/A
5398N/ATPNO= 9370
5398N/A
5398N/Ainclude $(WS_MAKE_RULES)/prep.mk
5398N/Ainclude $(WS_MAKE_RULES)/configure-64.mk
5398N/Ainclude $(WS_MAKE_RULES)/ips.mk
5398N/A
5398N/A# While the tree currently builds with Studio, we need to make sure it also
5398N/A# builds with gcc when submitting patches upstream, and having both sets of
5398N/A# options in the CFLAGS below makes it easy to switch when needed.
5398N/A# COMPILER=gcc
5398N/ACC += $(CC_BITS)
5398N/A
5398N/A# Enable additional warnings, since we've modified this code a lot
5398N/ACFLAGS.studio += -v
5398N/ACFLAGS.gcc += -Wall
5398N/A
5398N/A# Additional optimization flags, to make the hacks show off the hardware
5398N/A# better and because for just a screensaver display we can get away with
5398N/A# using optimizations that may change strict correctness of floating point ops.
5398N/ACFLAGS.studio += -fsimple=2 -nofstore -xlibmil -xprefetch
5398N/ACFLAGS.gcc += -funsafe-math-optimizations
5398N/A
5398N/A# Regenerate configure after patches modify configure.in
5398N/ACOMPONENT_PREP_ACTION += ( cd $(@D); autoreconf -fiv);
5398N/A
5398N/A# Need to pick up the GNU version of xgettext.
5398N/APATH=$(GNUBIN):/usr/bin
5398N/A
5398N/A# Libraries & programs to depend on
5398N/ACONFIGURE_OPTIONS += --with-gl=$(USRDIR)
5398N/ACONFIGURE_OPTIONS += --with-gtk=$(USRDIR)
5398N/ACONFIGURE_OPTIONS += --with-jpeg=$(USRDIR)
5398N/ACONFIGURE_OPTIONS += --without-motif
5398N/ACONFIGURE_OPTIONS += --with-pixbuf=$(USRDIR)
5398N/ACONFIGURE_OPTIONS += --with-xft=$(USRDIR)
5398N/ACONFIGURE_OPTIONS += PTHREAD_CFLAGS="-D_POSIX_PTHREAD_SEMANTICS"
5398N/ACONFIGURE_OPTIONS += PTHREAD_LIBS="-lc"
5398N/ACONFIGURE_OPTIONS += PERL=$(PERL)
5398N/ACONFIGURE_OPTIONS += INTLTOOL_PERL=$(PERL)
5398N/A
5398N/A# X extensions to support
5398N/ACONFIGURE_OPTIONS += --with-dpms-ext
5398N/ACONFIGURE_OPTIONS += --with-randr-ext
5398N/ACONFIGURE_OPTIONS += --with-xinerama-ext
5398N/ACONFIGURE_OPTIONS += --with-xinput-ext # required for accessibility
5398N/A
5398N/A# Support locking the screen by normal users and by root
5398N/ACONFIGURE_OPTIONS += --enable-locking
5398N/ACONFIGURE_OPTIONS += --enable-root-passwd
5398N/A# and allow user switching from the lock screen with gdmflexiserver
5398N/ACONFIGURE_OPTIONS += --with-login-manager
5398N/A
5398N/A# Use only PAM, not direct /etc/shadow or kerberos access
5398N/ACONFIGURE_OPTIONS += --with-pam=$(USRDIR)
5398N/ACONFIGURE_OPTIONS += --without-shadow
5398N/ACONFIGURE_OPTIONS += --without-kerberos
5398N/A
5398N/A# Paths to install to
5398N/AAPP_DEFAULTS_DIR = $(CONFIGURE_PREFIX)/share/X11/app-defaults
5398N/AXSS_LIBDIR = $(CONFIGURE_PREFIX)/lib/xscreensaver
5398N/ACONFIGURE_OPTIONS += --bindir=$(CONFIGURE_BINDIR.32)
5398N/ACONFIGURE_OPTIONS += --libexecdir=$(XSS_LIBDIR)/bin
5398N/ACONFIGURE_OPTIONS += --with-hackdir=$(XSS_LIBDIR)/hacks
5398N/ACONFIGURE_OPTIONS += --with-configdir=$(XSS_LIBDIR)/config/control-center-2.0
5398N/ACONFIGURE_OPTIONS += --with-x-app-defaults=$(APP_DEFAULTS_DIR)
5398N/A
5398N/A# Data sources for images & text in hacks
5398N/ACONFIGURE_OPTIONS += --with-image-directory=$(USRSHAREDIR)/pixmaps/backgrounds
5398N/ACONFIGURE_OPTIONS += --with-text-file=/etc/motd
5398N/A
5398N/A# Do not install setuid hacks
5398N/ACONFIGURE_OPTIONS += --without-setuid-hacks
5398N/A
5398N/A# The potfiles.in updates don't work unless source is cloned to build dir
5398N/ACOMPONENT_PRE_CONFIGURE_ACTION += ($(CLONEY) $(SOURCE_DIR) $(@D));
5398N/A
5398N/A# Update potfiles.in to pick up our added sources like lock-Gtk.c
5398N/A# The "-o Makefile" & touch stamp-it is needed to avoid infinite looping.
5398N/ACOMPONENT_POST_CONFIGURE_ACTION += ( \
5398N/A cd $(@D)/po ; \
5398N/A $(MAKE) -o Makefile generate_potfiles_in ; \
5398N/A $(MAKE) -o Makefile POTFILES ; \
5398N/A $(MAKE) -o Makefile xscreensaver.pot ; \
5398N/A touch stamp-it )
5398N/A
5398N/A# Recognizing DESTDIR as most autotools packages do would be too easy,
5398N/A# so xscreensaver makes us override install_prefix instead for the same effect.
5398N/ACOMPONENT_INSTALL_ARGS += install_prefix=$(PROTO_DIR)
5398N/A
5398N/A# Remove hacks we've chosen not to ship at all for various reasons
5398N/AREMOVED_HACKS="extrusion flyingtoasters ljlatest sonar webcollage"
5398N/ACOMPONENT_POST_INSTALL_ACTION += ( \
5398N/Afor h in $(REMOVED_HACKS) ; do \
5398N/A rm -f $(PROTO_DIR)$(XSS_LIBDIR)/hacks/$${h} \
5398N/A $(PROTO_DIR)$(CONFIGURE_MANDIR)/man6/$${h}.6 \
5398N/A $(PROTO_DIR)$(XSS_LIBDIR)/config/control-center-2.0/$${h}.xml ;\
5398N/Adone ; \
5398N/Arm -f $(PROTO_DIR)$(XSS_LIBDIR)/hacks/webcollage-helper );
5398N/A
5398N/A
5398N/AASLR_MODE = $(ASLR_ENABLE)
5398N/A
5398N/Aconfigure: $(CONFIGURE_64)
5398N/Abuild: $(BUILD_64)
5398N/Ainstall: $(INSTALL_64)
5398N/Atest: $(NO_TESTS)
5398N/Asystem-test: $(NO_TESTS)
5398N/A
5398N/A
5398N/AREQUIRED_PACKAGES += gnome/accessibility/gnome-a11y-libs
5398N/AREQUIRED_PACKAGES += gnome/config/gconf
5398N/AREQUIRED_PACKAGES += image/library/libjpeg
5398N/AREQUIRED_PACKAGES += library/desktop/atk
5398N/AREQUIRED_PACKAGES += library/desktop/gdk-pixbuf
5398N/AREQUIRED_PACKAGES += library/desktop/gtk2
5398N/AREQUIRED_PACKAGES += library/desktop/libglade
5398N/AREQUIRED_PACKAGES += library/desktop/pango
5398N/AREQUIRED_PACKAGES += library/glib2
5398N/AREQUIRED_PACKAGES += library/gnome/gnome-component
5398N/AREQUIRED_PACKAGES += library/libxml2
5398N/AREQUIRED_PACKAGES += library/perl-5/xml-parser
5398N/AREQUIRED_PACKAGES += $(PERL_PKG)
5398N/AREQUIRED_PACKAGES += system/library
5398N/AREQUIRED_PACKAGES += system/library/math
5398N/AREQUIRED_PACKAGES += x11/library/libx11
5398N/AREQUIRED_PACKAGES += x11/library/libxext
5398N/AREQUIRED_PACKAGES += x11/library/libxft
5398N/AREQUIRED_PACKAGES += x11/library/libxi
5398N/AREQUIRED_PACKAGES += x11/library/libxinerama
5398N/AREQUIRED_PACKAGES += x11/library/libxmu
5398N/AREQUIRED_PACKAGES += x11/library/libxrandr
5398N/AREQUIRED_PACKAGES += x11/library/libxxf86misc
5398N/AREQUIRED_PACKAGES += x11/library/libxxf86vm
5398N/AREQUIRED_PACKAGES += x11/library/mesa
5398N/AREQUIRED_PACKAGES += x11/library/toolkit/libxt