Makefile revision 5636
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# CDDL HEADER START
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# The contents of this file are subject to the terms of the
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# Common Development and Distribution License (the "License").
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# You may not use this file except in compliance with the License.
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# See the License for the specific language governing permissions
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# and limitations under the License.
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# When distributing Covered Code, include this CDDL HEADER in each
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# If applicable, add the following below this CDDL HEADER, with the
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# fields enclosed by brackets "[]" replaced with your own identifying
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# information: Portions Copyright [yyyy] [name of copyright owner]
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# CDDL HEADER END
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerCOMPONENT_PROJECT_URL= https://www.jwz.org/xscreensaver/
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerCOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer sha256:6fff7ec4be743e5c042647ea9687dd0cdf48d1dd5e8e15098e5018bbd02e5e27
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerCOMPONENT_ARCHIVE_URL= https://www.jwz.org/xscreensaver/$(COMPONENT_ARCHIVE)
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# While the tree currently builds with Studio, we need to make sure it also
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# builds with gcc when submitting patches upstream, and having both sets of
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# options in the CFLAGS below makes it easy to switch when needed.
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# COMPILER=gcc
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# Enable additional warnings, since we've modified this code a lot
744e50acbaaf22481b25b921b2bc199c8dd4a35cStephen Brooks# Additional optimization flags, to make the hacks show off the hardware
744e50acbaaf22481b25b921b2bc199c8dd4a35cStephen Brooks# better and because for just a screensaver display we can get away with
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# using optimizations that may change strict correctness of floating point ops.
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerCFLAGS.studio += -fsimple=2 -nofstore -xlibmil -xprefetch
7656b92221e26376547b0dc52b67e7a414ea9775Stephen Brooks# Regenerate configure after patches modify configure.in
7656b92221e26376547b0dc52b67e7a414ea9775Stephen BrooksCOMPONENT_PREP_ACTION += ( cd $(@D); autoreconf -fiv);
7a0878494fd11b7a861d0b3e2034534c10b5fb46Stephen Brooks# Need to pick up the GNU version of xgettext.
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# Libraries & programs to depend on
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerCONFIGURE_OPTIONS += PTHREAD_CFLAGS="-D_POSIX_PTHREAD_SEMANTICS"
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# X extensions to support
7656b92221e26376547b0dc52b67e7a414ea9775Stephen BrooksCONFIGURE_OPTIONS += --with-xinput-ext # required for accessibility
7656b92221e26376547b0dc52b67e7a414ea9775Stephen Brooks# Support locking the screen by normal users and by root
7656b92221e26376547b0dc52b67e7a414ea9775Stephen Brooks# and allow user switching from the lock screen with gdmflexiserver
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# Use only PAM, not direct /etc/shadow or kerberos access
7a0878494fd11b7a861d0b3e2034534c10b5fb46Stephen Brooks# Paths to install to
7a0878494fd11b7a861d0b3e2034534c10b5fb46Stephen BrooksAPP_DEFAULTS_DIR = $(CONFIGURE_PREFIX)/share/X11/app-defaults
7a0878494fd11b7a861d0b3e2034534c10b5fb46Stephen BrooksXSS_LIBDIR = $(CONFIGURE_PREFIX)/lib/xscreensaver
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerCONFIGURE_OPTIONS += --bindir=$(CONFIGURE_BINDIR.32)
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerCONFIGURE_OPTIONS += --libexecdir=$(XSS_LIBDIR)/bin
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerCONFIGURE_OPTIONS += --with-hackdir=$(XSS_LIBDIR)/hacks
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerCONFIGURE_OPTIONS += --with-configdir=$(XSS_LIBDIR)/config/control-center-2.0
7656b92221e26376547b0dc52b67e7a414ea9775Stephen BrooksCONFIGURE_OPTIONS += --with-x-app-defaults=$(APP_DEFAULTS_DIR)
7656b92221e26376547b0dc52b67e7a414ea9775Stephen Brooks# Data sources for images & text in hacks
7656b92221e26376547b0dc52b67e7a414ea9775Stephen BrooksCONFIGURE_OPTIONS += --with-image-directory=$(USRSHAREDIR)/pixmaps/backgrounds
7656b92221e26376547b0dc52b67e7a414ea9775Stephen BrooksCONFIGURE_OPTIONS += --with-text-file=/etc/motd
7656b92221e26376547b0dc52b67e7a414ea9775Stephen Brooks# Do not install setuid hacks
7656b92221e26376547b0dc52b67e7a414ea9775Stephen Brooks# The potfiles.in updates don't work unless source is cloned to build dir
7656b92221e26376547b0dc52b67e7a414ea9775Stephen BrooksCOMPONENT_PRE_CONFIGURE_ACTION += ($(CLONEY) $(SOURCE_DIR) $(@D));
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# Update potfiles.in to pick up our added sources like lock-Gtk.c
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# The "-o Makefile" & touch stamp-it is needed to avoid infinite looping.
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# Recognizing DESTDIR as most autotools packages do would be too easy,
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# so xscreensaver makes us override install_prefix instead for the same effect.
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerCOMPONENT_INSTALL_ARGS += install_prefix=$(PROTO_DIR)
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer# Remove hacks we've chosen not to ship at all for various reasons
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerREMOVED_HACKS="extrusion flyingtoasters ljlatest sonar webcollage"
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremer $(PROTO_DIR)$(XSS_LIBDIR)/config/control-center-2.0/$${h}.xml ;\
e4f5a11d4a234623168c1558fcdf4341e11769e1James Kremerrm -f $(PROTO_DIR)$(XSS_LIBDIR)/hacks/webcollage-helper );
e4f5a11d4a234623168c1558fcdf4341e11769e1James KremerREQUIRED_PACKAGES += gnome/accessibility/gnome-a11y-libs
744e50acbaaf22481b25b921b2bc199c8dd4a35cStephen BrooksREQUIRED_PACKAGES += library/desktop/gdk-pixbuf