Makefile revision 1231
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync###############################################################################
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# xterm Makefile
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Copyright (c) 2008, 2011, Oracle and/or its affiliates. All rights reserved.
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Permission is hereby granted, free of charge, to any person obtaining a
7eaaa8a4480370b82ef3735994f986f338fb4df2vboxsync# copy of this software and associated documentation files (the "Software"),
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# to deal in the Software without restriction, including without limitation
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# the rights to use, copy, modify, merge, publish, distribute, sublicense,
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# and/or sell copies of the Software, and to permit persons to whom the
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Software is furnished to do so, subject to the following conditions:
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# The above copyright notice and this permission notice (including the next
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# paragraph) shall be included in all copies or substantial portions of the
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
9040f019271f91b98e1320c0a8c38a42636e3979vboxsync# DEALINGS IN THE SOFTWARE.
9040f019271f91b98e1320c0a8c38a42636e3979vboxsync# Package name used in tarballs
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# pkg(5) name we deliver the files in (override default)
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# resize goes into a separate package so it can be installed in zones without
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# X, but which you login to from a resizable GUI terminal window.
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Package classification (override default)
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Package metadata
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Version number (used in path names)
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Checksums for upstream tarball
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncTARBALL_SHA1 = 53586916147cb88e71b3d620a7d1b80f1696749b
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Source tarball
9040f019271f91b98e1320c0a8c38a42636e3979vboxsyncSOURCE_URL=ftp://invisible-island.net/xterm/$(SOURCE_TARBALL_NAME:.tar.gz=.tgz)
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Source tarball
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncSOURCE_TARBALL_NAME=$(MODULE_NAME)-$(MODULE_VERSION).tar.gz
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Patches to apply to source after unpacking, in order
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncSOURCE_PATCHES = resize.man.patch,-p1 desktop-icon.patch,-p1
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Man pages to apply Sun footer to & attributes to list
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncSUNTOUCHED_MANPAGES=koi8rxterm.man resize.man uxterm.man xterm.man
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Fix man page footers to not say "Last changed: X Window System"
bbf3d430bae83177ab9ce3097f49d89cc873e7c0vboxsyncMODULE_SUNTOUCH_MAN_FLAGS = -r '{__vendorversion__, $(XVENDORVERS)}'
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Override specific attributes for specific man pages
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync $(SUNTOUCH_MAN_FLAGS_$(@F:%.man.$(FIXED_MAN_SUFFIX)=%))
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncSUNTOUCH_MAN_FLAGS_resize = -o '{Availability, $(RESIZE_PKGNAME)}'
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Paths to find Xft/fontconfig/freetype headers libraries at build time
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# and run time
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncFT_CFLAGS= -I$(PROTODIR)/usr/include -I$(PROTODIR)/usr/include/freetype2
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync -L$(PROTODIR)/usr/lib$(LIBSUBDIR) -R/usr/lib$(LIBSUBDIR) -lXft -lfontconfig
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Override the flags xterm's configure script generates, since it incorrectly
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# adds -R flags pointing to the build proto area, which are not wanted.
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync LDFLAGS="$(DEFAULT_CONFIG_LDFLAGS) $(MODTYPE_CFLAGS) $(MODTYPE_LDFLAGS)"
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Additional flags to pass to configure script
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncMODULE_CONFIG_OPTS = --enable-256-color --enable-88-color --enable-wide-chars \
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync --with-freetype-cflags="$(FT_CFLAGS)" --with-freetype-libs="$(FT_LIBS)" \
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync --disable-setuid --disable-setgid --enable-luit --disable-imake \
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync --x-includes=$(PROTODIR)$(X11_INCLUDES_DIR) --x-libraries=$(X11_LIB_DIR) \
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Sort-of emulate automake silent rules - run make configure V=1 to see
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# full compiler flags
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncMODULE_CONFIG_OPTS_VERBOSE_ = $(MODULE_CONFIG_OPTS_VERBOSE_0)
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncMODULE_CONFIG_OPTS += $(MODULE_CONFIG_OPTS_VERBOSE_$(V))
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Tell configure where to find luit binary
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncMODULE_ADD_INSTALL_TARGETS=install_docs install_desktop
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Install documentation of xterm control sequences for packaging
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncPROTO_CTLSEQS=$(PROTODIR)$(MODULE_DOCDIR)/ctlseqs.txt
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Install desktop file to allow starting xterm from GNOME menu
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncPROTO_DESKTOP=$(PROTODIR)$(DESKTOP_DIR)/xterm.desktop
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsync# Metadata for separate package for resize
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncRESIZE_PKG_METADATA_DIR = $(MODULE_PKG_METADATA_DIR:%xterm=%resize)
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncRESIZE_PKG_ATTRDATA_FILE = $(RESIZE_PKG_METADATA_DIR)/$(ATTRDATA_FILE_NAME)
c1f5ec452b23d55c71e6f07628b84ac5e97cf551vboxsyncRESIZE_PKG_LICENSE_FILE = $(RESIZE_PKG_METADATA_DIR)/$(LICENSE_FILE_NAME)