792N/A###############################################################################
792N/A#
1339N/A# xdm - X Display Manager with support for XDMCP and host chooser
792N/A#
1453N/A# Copyright (c) 2009, 2015, Oracle and/or its affiliates. All rights reserved.
792N/A#
792N/A# Permission is hereby granted, free of charge, to any person obtaining a
919N/A# copy of this software and associated documentation files (the "Software"),
919N/A# to deal in the Software without restriction, including without limitation
919N/A# the rights to use, copy, modify, merge, publish, distribute, sublicense,
919N/A# and/or sell copies of the Software, and to permit persons to whom the
919N/A# Software is furnished to do so, subject to the following conditions:
919N/A#
919N/A# The above copyright notice and this permission notice (including the next
919N/A# paragraph) shall be included in all copies or substantial portions of the
919N/A# Software.
919N/A#
919N/A# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
919N/A# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
919N/A# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
919N/A# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
919N/A# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
919N/A# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
919N/A# DEALINGS IN THE SOFTWARE.
792N/A#
792N/A#
792N/A
792N/A# Package name used in tarballs
792N/AMODULE_NAME=xdm
792N/A
970N/A# pkg(5) name we deliver the files in (override default)
970N/AMODULE_PKGNAME=system/display-manager/xdm
970N/AMODULE_PKGNAME_SET=yes
1339N/AMODULE_DESC = the X Display Manager (xdm) server
970N/A
792N/A# Version number (used in path names)
792N/AMODULE_VERSION=1.1.9
792N/A
911N/A# Checksums for upstream tarball
911N/ATARBALL_MD5 = 030ae4bd9b8d428749d68bfdf56ce8a5
911N/ATARBALL_SHA1 = ea0ee2923999d54848dc8a165867ffa7c628fd7b
911N/A
792N/A# Patches to apply to source after unpacking, in order
792N/ASOURCE_PATCHES = \
792N/A mkdir.patch,-p1 \
1141N/A pam_tty.patch,-p1 \
1141N/A pam_user.patch,-p1 \
1447N/A greeter-linking.patch,-p1 \
1199N/A bindir.patch,-p1 \
792N/A terminateServer.patch \
930N/A bug-6822636.patch \
924N/A bug-6820612.patch,-p1 \
1453N/A Xsession.patch \
1456N/A 18286609.patch,-p1 \
1456N/A 20508188.patch,-p1
792N/A
1199N/A# Need to rebuild configure/Makefile.in after applying bindir.patch
1199N/AAUTORECONF=yes
1199N/A
792N/A# Man pages to apply Sun footer to & attributes to list
792N/ASUNTOUCHED_MANPAGES=xdm.man.cpp
792N/AMODULE_STABILITY=Committed
792N/AMODULE_SUNTOUCH_MAN_FLAGS= -p $(MODULE_PREFIX)/sbin/
792N/A
792N/A# Where to install xdm files
792N/AMODULE_PREFIX=/usr
792N/AMODULE_PREFIX_SET=yes
792N/A
792N/A# Additional configure script options
792N/A# Only build shared greeter module, not static
792N/A# Set various paths to better match Solaris
1199N/A# Find xrdb & xterm in /usr/bin even with --bindir set to /usr/sbin
792N/AMODULE_CONFIG_OPTS= \
792N/A --enable-shared=yes --enable-static=no \
792N/A --with-xdmconfigdir=/etc/X11/xdm \
792N/A --with-piddir=/var/run/xdm \
792N/A --with-authdir=/var/run/xdm \
792N/A --bindir=/usr/sbin \
1199N/A --with-xrdb='$(X11_BIN_DIR)/xrdb' \
1199N/A --with-default-session=command='$(X11_BIN_DIR)/xterm -ls' \
1199N/A DEF_SERVER='$(X11_BIN_DIR)/X' \
1197N/A DEF_USER_PATH=/usr/bin:/usr/sbin \
1197N/A DEF_SYSTEM_PATH=/usr/bin:/usr/sbin
792N/A
1196N/A# configure scripts add libraries like -lXt & -lXinerama to the global $(LIBS)
1196N/A# when only some objects need them, so ignore them in the rest.
1447N/AMODULE_LD_OPTIONS = $(ZDISCARD_UNUSED_DEP)
1447N/A# but it misses adding -lc to the greeter shared object, so add it
1447N/AMODULE_LD_OPTIONS += -lc
1196N/A
792N/A# Additional build & install targets
792N/AMODULE_ADD_BUILD_TARGETS=build_xdm_configs
792N/AMODULE_ADD_INSTALL_TARGETS=install_xdmshell install_xdm_configs
792N/A
1097N/A# Need to fix libtool interference with our linker flags
1097N/ADELIBTOOLIZE=yes
1097N/A
792N/Ainclude ../Makefile.inc
792N/A
792N/A# Move xdmshell from default location to the place we put in our packages
792N/Ainstall_xdmshell: default_install
792N/A -rm -f $(PROTODIR)/usr/lib/X11/xdm/xdmshell
792N/A mv $(PROTODIR)/usr/sbin/xdmshell $(PROTODIR)/usr/lib/X11/xdm/xdmshell
792N/A
792N/A# Copy xdm config files from /etc to /usr for use as prototypes
792N/AXDM_CONFIG_FILES=Xaccess Xresources Xservers xdm-config
792N/AXDM_ETC_CONFIGDIR=/etc/X11/xdm
792N/AXDM_USR_CONFIGDIR=/usr/lib/X11/xdm
792N/AXCF_USR_FILES=$(XDM_CONFIG_FILES:%=$(PROTODIR)/$(XDM_USR_CONFIGDIR)/%)
792N/AXCF_ETC_SRCDIR=$(SOURCE_DIR)/config
1422N/AXCF_ETC_BLDDIR=$(BUILD_DIR)/config
1422N/AXCF_ETC_BLDFILES=$(XDM_CONFIG_FILES:%=$(XCF_ETC_BLDDIR)/%)
1422N/AXCF_USR_BLDDIR=$(BUILD_DIR)/config/annotated
1422N/AXCF_USR_BLDFILES=$(XDM_CONFIG_FILES:%=$(XCF_USR_BLDDIR)/%)
792N/A
792N/Abuild_xdm_configs: $(XCF_USR_SRCFILES)
792N/Ainstall_xdm_configs: $(XCF_USR_FILES) $(PROTODIR)/$(XDM_USR_CONFIGDIR)/README
1422N/A$(XCF_ETC_BLDFILES): default_build
792N/A
792N/AXCF_HEADER = %1$$s----------------------------------------------------------------------------
792N/AXCF_HEADER += \n%1$$s NOTE: The file provided in $(XDM_USR_CONFIGDIR) is a sample %2$$s
792N/AXCF_HEADER += \n%1$$s configuration file provided for your reference.
792N/AXCF_HEADER += \n%1$$s
792N/AXCF_HEADER += \n%1$$s xdm reads the actual configuration from the copies located in $(XDM_ETC_CONFIGDIR)
792N/AXCF_HEADER += \n%1$$s (unless configured otherwise by $(XDM_ETC_CONFIGDIR)/xdm-config or
792N/AXCF_HEADER += \n%1$$s a file specified via the -config command line option).
792N/AXCF_HEADER += \n%1$$s----------------------------------------------------------------------------\n
792N/A
1422N/A$(PROTODIR)/$(XDM_USR_CONFIGDIR) $(XCF_USR_BLDDIR):
792N/A mkdir -p $@
792N/A
1422N/A$(XCF_USR_FILES): $(PROTODIR)/$(XDM_USR_CONFIGDIR) $(XCF_USR_BLDFILES)
792N/A -rm -f $@
792N/A mkdir -p $(PROTODIR)/$(XDM_USR_CONFIGDIR)
1422N/A cp -p $(XCF_USR_BLDDIR)/$(@F) $@
792N/A
1422N/A$(XCF_USR_BLDFILES): $(XCF_USR_BLDDIR) $(XCF_ETC_BLDFILES)
792N/A -rm -f $@
967N/A FILENAME=$(@F) ; \
1422N/A if [[ -f $(XCF_ETC_BLDDIR)/$${FILENAME} ]] ; then \
1422N/A ORIGFILE="$(XCF_ETC_BLDDIR)/$${FILENAME}" ; \
1422N/A else \
1422N/A ORIGFILE="$(XCF_ETC_SRCDIR)/$${FILENAME}" ; \
1422N/A fi ; \
1422N/A COMMENT_CHAR=$$(head -n 1 $${ORIGFILE}) ; \
792N/A printf '$(XCF_HEADER)' $${COMMENT_CHAR} $${FILENAME} > $@ ; \
1422N/A cat $${ORIGFILE} >> $@
792N/A
792N/A$(PROTODIR)/$(XDM_USR_CONFIGDIR)/README:$(PROTODIR)/$(XDM_USR_CONFIGDIR) config-README.txt
792N/A cp -p config-README.txt $@