open-src/xserver/xorg/Makefile
author Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
Fri, 18 Jun 2010 08:41:15 -0700
changeset 963 7a4fced80e83
parent 952 a6e7000b9e48
child 965 c096efd79ce7
permissions -rw-r--r--
6962316 X proto area should more closely match packages
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     1
###############################################################################
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     2
#
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     3
# Xorg server Makefile
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     4
#
935
f812f9863e75 6941861 Collected X gate build fixes
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 931
diff changeset
     5
# Copyright (c) 2006, 2010, Oracle and/or its affiliates. All rights reserved.
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     6
#
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     7
# Permission is hereby granted, free of charge, to any person obtaining a
919
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
     8
# copy of this software and associated documentation files (the "Software"),
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
     9
# to deal in the Software without restriction, including without limitation
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    10
# the rights to use, copy, modify, merge, publish, distribute, sublicense,
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    11
# and/or sell copies of the Software, and to permit persons to whom the
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    12
# Software is furnished to do so, subject to the following conditions:
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    13
#
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    14
# The above copyright notice and this permission notice (including the next
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    15
# paragraph) shall be included in all copies or substantial portions of the
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    16
# Software.
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    17
#
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    18
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    19
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    20
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    21
# THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    22
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    23
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
425233ae7236 6931307 Standardize Sun copyright & license notices in X gate on current format
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 916
diff changeset
    24
# DEALINGS IN THE SOFTWARE.
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    25
#
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    26
#
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    27
235
06772554f851 6572087 ship Xvnc for Solaris [PSARC/2007/545]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 234
diff changeset
    28
# Build 32-bit or 64-bit?
156
1dec9ce4addc 6551329 X open-src makefiles spawn too many shell commands
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 154
diff changeset
    29
BUILD_TYPES_SET=yes
1dec9ce4addc 6551329 X open-src makefiles spawn too many shell commands
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 154
diff changeset
    30
BUILD_TYPES_sparc=64
1dec9ce4addc 6551329 X open-src makefiles spawn too many shell commands
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 154
diff changeset
    31
BUILD_TYPES_i386=32 64
1dec9ce4addc 6551329 X open-src makefiles spawn too many shell commands
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 154
diff changeset
    32
BUILD_TYPES=$(BUILD_TYPES_$(MACH))
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    33
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    34
# Package name used in tarballs
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    35
MODULE_NAME=xorg-server
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    36
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    37
# Version number (used in path names)
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    38
MODULE_VERSION=$(XORGSERVER_VERS)
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    39
911
a3e7e197651c 6929667 Automate downloading and verification of tarballs used to build X gate
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 910
diff changeset
    40
# Checksums for upstream tarball
952
a6e7000b9e48 6954535 Update Xorg from 1.7.6 to 1.7.7
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 947
diff changeset
    41
TARBALL_MD5  = 8c0146330fb155c23d947ac37d431d4b
a6e7000b9e48 6954535 Update Xorg from 1.7.6 to 1.7.7
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 947
diff changeset
    42
TARBALL_SHA1 = 0f1b71363843b7e394d6de62d0db5b74d3e645ef
911
a3e7e197651c 6929667 Automate downloading and verification of tarballs used to build X gate
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 910
diff changeset
    43
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    44
# Patches to apply to source after unpacking, in order
235
06772554f851 6572087 ship Xvnc for Solaris [PSARC/2007/545]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 234
diff changeset
    45
# *** Moved to patch-list file so they can be shared between Xorg & Xvnc builds
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    46
SOURCE_PATCHES=$(XORG_SOURCE_PATCHES)
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    47
916
a2113251a45c 6928167 Integrate X server mdb module into xorg-server build & packages (fix SPARC build)
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 913
diff changeset
    48
# Used in rules shared between Xorg & Xvnc builds in Makefile.inc
a2113251a45c 6928167 Integrate X server mdb module into xorg-server build & packages (fix SPARC build)
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 913
diff changeset
    49
# to allow for different source layouts
a2113251a45c 6928167 Integrate X server mdb module into xorg-server build & packages (fix SPARC build)
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 913
diff changeset
    50
XORG_BUILD_DIR=$(SOURCE_DIR)
a2113251a45c 6928167 Integrate X server mdb module into xorg-server build & packages (fix SPARC build)
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 913
diff changeset
    51
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    52
# Man pages to apply Sun footer to & attributes to list
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    53
# XXX: Need to adjust some of these to correct packages/stability
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    54
SUNTOUCHED_MANPAGES= \
606
068c11b419c9 6582489 X11R7.4: Xorg server 1.5.3, Mesa 7.2, and associated driver updates
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 591
diff changeset
    55
	hw/kdrive/ephyr/Xephyr.man.pre \
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    56
	hw/xfree86/utils/gtf/gtf.man.pre \
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    57
	hw/xfree86/utils/cvt/cvt.man.pre \
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    58
	hw/xfree86/doc/man/Xorg.man.pre \
606
068c11b419c9 6582489 X11R7.4: Xorg server 1.5.3, Mesa 7.2, and associated driver updates
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 591
diff changeset
    59
	hw/xfree86/doc/man/xorg.conf.man.pre \
068c11b419c9 6582489 X11R7.4: Xorg server 1.5.3, Mesa 7.2, and associated driver updates
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 591
diff changeset
    60
	hw/vfb/Xvfb.man.pre
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    61
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    62
SUN_PACKAGE=SUNWxorg-server
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    63
MODULE_STABILITY=Volatile
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    64
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    65
# Binary built in tree
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    66
XORGSERVER_BIN=$(SOURCE_DIR)/hw/xfree86/Xorg
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    67
908
ee1047befc15 6928167 Integrate X server mdb module into xorg-server build & packages
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
    68
BUILD_TARGETS=$(XORGSERVER_BIN) build_mdb set-elf-comments \
591
a2c6b61a92aa 6777135 X builds should record version info in ELF comments
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 587
diff changeset
    69
	$(BUILD_DIR)/mapfile-Xorg-externs
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    70
BUILD_TARGETS_SET=yes
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    71
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    72
# Need to regenerate autoconf/automake files after patching
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    73
AUTORECONF=yes
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    74
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    75
# Command line options to GNU autoconf configure script
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    76
#  Need to override LD setting to add -xarch flags that libtool strips
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    77
# XXX: --disable-dga
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    78
MODULE_CONFIG_OPTS = $(XSERVER_CONFIG_OPTS) \
705
24ca414edbff 6826940 Xorg server 1.6.1, Mesa 7.4.1, and associated module upgrades [PSARC 2009/292]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 670
diff changeset
    79
        --enable-builddocs \
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    80
	--enable-kdrive --enable-xephyr --disable-xsdl \
557
3e9830015f69 6748087 move Xprt to open-src and /usr/X11 [fix install of Xprt fonts]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 555
diff changeset
    81
	MKFONTDIR="$(MKFONTDIR)" \
3e9830015f69 6748087 move Xprt to open-src and /usr/X11 [fix install of Xprt fonts]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 555
diff changeset
    82
	MKFONTSCALE="$(MKFONTSCALE)" \
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    83
	LD="$(CC) $(ARCH_FLAGS)"
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 355
diff changeset
    84
606
068c11b419c9 6582489 X11R7.4: Xorg server 1.5.3, Mesa 7.2, and associated driver updates
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 591
diff changeset
    85
# pkg-config files that need to have -R added
068c11b419c9 6582489 X11R7.4: Xorg server 1.5.3, Mesa 7.2, and associated driver updates
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 591
diff changeset
    86
FIX_PC_FILES=xorg-server.pc.in
851
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
    87
# Remove compiler specific visibility flag that breaks builds of drivers
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
    88
# with other compilers
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
    89
MODULE_FIX_PC_FLAGS= -e 's|\@symbol_visibility\@||'
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
    90
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
    91
# Need to use GNU Make to build due to hw/xfree86/loader
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
    92
MODULE_MAKE=$(GNUMAKE)
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
    93
MODULE_MAKE_SET=yes
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    94
591
a2c6b61a92aa 6777135 X builds should record version info in ELF comments
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 587
diff changeset
    95
# Additional install targets beyond the defaults
963
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
    96
MODULE_ADD_INSTALL_TARGETS=install_extras install_mdb install_pc_common \
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
    97
	install_fix_paths
851
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
    98
EXTRA_INSTALL_sparc=install_pc_copy
591
a2c6b61a92aa 6777135 X builds should record version info in ELF comments
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 587
diff changeset
    99
EXTRA_INSTALL_i386=
910
0a08683bf637 6928500 Race conditions in parallel make break X nightly builds
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 908
diff changeset
   100
MODULE_ADD_INSTALL_TARGETS += $(EXTRA_INSTALL_$(MACH))
0a08683bf637 6928500 Race conditions in parallel make break X nightly builds
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 908
diff changeset
   101
0a08683bf637 6928500 Race conditions in parallel make break X nightly builds
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 908
diff changeset
   102
# Have to avoid dependency loop between install_pc_copy and 
0a08683bf637 6928500 Race conditions in parallel make break X nightly builds
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 908
diff changeset
   103
# install_pkgconfig_uninstalled
0a08683bf637 6928500 Race conditions in parallel make break X nightly builds
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 908
diff changeset
   104
INSTALL_PCU_DEPS = $(INSTALL_TARGETS:install_pc_copy=)
0a08683bf637 6928500 Race conditions in parallel make break X nightly builds
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 908
diff changeset
   105
INSTALL_PCU_DEPS_SET=yes
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   106
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   107
# Merge in additional sources from sun-src directory
910
0a08683bf637 6928500 Race conditions in parallel make break X nightly builds
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 908
diff changeset
   108
ADDITIONAL_SOURCE_DIR=sun-src
0a08683bf637 6928500 Race conditions in parallel make break X nightly builds
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 908
diff changeset
   109
0a08683bf637 6928500 Race conditions in parallel make break X nightly builds
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 908
diff changeset
   110
include ../Makefile.inc
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   111
606
068c11b419c9 6582489 X11R7.4: Xorg server 1.5.3, Mesa 7.2, and associated driver updates
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 591
diff changeset
   112
$(XORGSERVER_BIN): default_build
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   113
606
068c11b419c9 6582489 X11R7.4: Xorg server 1.5.3, Mesa 7.2, and associated driver updates
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 591
diff changeset
   114
SDK_INCLUDES_DIR=$(PROTODIR)$(X11_INCLUDES_DIR)/xorg/
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   115
591
a2c6b61a92aa 6777135 X builds should record version info in ELF comments
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 587
diff changeset
   116
install_extras: default_install
851
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   117
	-rm -f $(SDK_INCLUDES_DIR)/xorg-server.h
111
651ef52cedbc 6525243 Nevada B58 32-bit Xorg crashes on a VMware VM
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 106
diff changeset
   118
	sed -e 's%#define XF86DRI 1%/* #define XF86DRI 1 */%' \
651ef52cedbc 6525243 Nevada B58 32-bit Xorg crashes on a VMware VM
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 106
diff changeset
   119
	    -e 's%^.* _XSERVER64 .*$$%#include <sys/isa_defs.h>\
651ef52cedbc 6525243 Nevada B58 32-bit Xorg crashes on a VMware VM
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 106
diff changeset
   120
#ifdef _LP64\
651ef52cedbc 6525243 Nevada B58 32-bit Xorg crashes on a VMware VM
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 106
diff changeset
   121
#define _XSERVER64 1\
651ef52cedbc 6525243 Nevada B58 32-bit Xorg crashes on a VMware VM
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 106
diff changeset
   122
#endif%' \
606
068c11b419c9 6582489 X11R7.4: Xorg server 1.5.3, Mesa 7.2, and associated driver updates
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 591
diff changeset
   123
	    $(SOURCE_DIR)/include/xorg-server.h > $(SDK_INCLUDES_DIR)/xorg-server.h
851
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   124
	cp -pf $(SOURCE_DIR)/mi/mioverlay.h $(SDK_INCLUDES_DIR)/mioverlay.h
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   125
	cp -pf $(SOURCE_DIR)/hw/xfree86/os-support/bus/xf86Sbus.h $(SDK_INCLUDES_DIR)/xf86Sbus.h
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   126
	cp -pf $(SOURCE_DIR)/hw/xfree86/dri/*.h $(SDK_INCLUDES_DIR)/
606
068c11b419c9 6582489 X11R7.4: Xorg server 1.5.3, Mesa 7.2, and associated driver updates
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 591
diff changeset
   127
	-rm -f $(SDK_INCLUDES_DIR)/xf1bpp.h $(SDK_INCLUDES_DIR)/xf4bpp.h
733
15c28bfd12ed 6854717 Add man pages to document replacements for EOF programs
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 705
diff changeset
   128
	mkdir -p $(PROTODIR)$(X11_MAN_DIR)/man1
15c28bfd12ed 6854717 Add man pages to document replacements for EOF programs
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 705
diff changeset
   129
	cp -pf $(SOURCE_DIR)/doc/Xnest.1 \
15c28bfd12ed 6854717 Add man pages to document replacements for EOF programs
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 705
diff changeset
   130
	       $(SOURCE_DIR)/hw/xfree86/doc/man/xorgcfg.1 \
15c28bfd12ed 6854717 Add man pages to document replacements for EOF programs
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 705
diff changeset
   131
	       $(SOURCE_DIR)/hw/xfree86/doc/man/xorgconfig.1 \
15c28bfd12ed 6854717 Add man pages to document replacements for EOF programs
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 705
diff changeset
   132
	       $(PROTODIR)$(X11_MAN_DIR)/man1
963
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   133
	mkdir -p $(PROTODIR)/etc/hal/fdi/preprobe/10osvendor
851
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   134
	cp -pf $(SOURCE_DIR)/config/x11-input.fdi \
963
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   135
	 $(PROTODIR)/etc/hal/fdi/preprobe/10osvendor/10-x11-input.fdi
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   136
851
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   137
# Workaround bug in installing pkgconfig file to wrong directory in 64-bit
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   138
# builds
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   139
install_pc_common: default_install
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   140
	-rm -f $(PROTODIR)$(PKGCONFIG_DIR)/xorg-server.pc
935
f812f9863e75 6941861 Collected X gate build fixes
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 931
diff changeset
   141
	mkdir -p $(PROTODIR)$(PKGCONFIG_DIR)
851
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   142
	cp -pf $(SOURCE_DIR)/xorg-server.pc \
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   143
		$(PROTODIR)$(PKGCONFIG_DIR)/xorg-server.pc
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   144
212
2c0330828853 6596598 Xorg headers should be delivered (fix xorg-server.pc delivery on SPARC)
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 207
diff changeset
   145
# Install xorg-server.pc in 32-bit pkgconfig dir on SPARC too
851
d428083dbbdd 6905171 X11R7.5 / Xorg 1.7.3 integration
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 810
diff changeset
   146
install_pc_copy: install_pc_common install_pkgconfig_uninstalled 
935
f812f9863e75 6941861 Collected X gate build fixes
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 931
diff changeset
   147
	-rm -f $(PROTODIR)$(PKGCONFIG_DIR_32)/xorg-server.pc \
606
068c11b419c9 6582489 X11R7.4: Xorg server 1.5.3, Mesa 7.2, and associated driver updates
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 591
diff changeset
   148
		$(PROTODIR)$(PKGCONFIG_DIR_32)/xorg-server-uninstalled.pc
935
f812f9863e75 6941861 Collected X gate build fixes
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 931
diff changeset
   149
	mkdir -p $(PROTODIR)$(PKGCONFIG_DIR_32)
f812f9863e75 6941861 Collected X gate build fixes
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 931
diff changeset
   150
	ln -s ../$(SUBDIR64)$(PKGCONFIG_DIR_suffix)/xorg-server.pc \
f812f9863e75 6941861 Collected X gate build fixes
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 931
diff changeset
   151
	    ../$(SUBDIR64)$(PKGCONFIG_DIR_suffix)/xorg-server-uninstalled.pc \
f812f9863e75 6941861 Collected X gate build fixes
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 931
diff changeset
   152
		$(PROTODIR)$(PKGCONFIG_DIR_32)/
212
2c0330828853 6596598 Xorg headers should be delivered (fix xorg-server.pc delivery on SPARC)
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 207
diff changeset
   153
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   154
$(BUILD_DIR)/mapfile-Xorg-externs: $(XORGSERVER_BIN)
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   155
	-rm -f $@
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   156
	printf '# Functions exported by Xorg server to loadable modules\n\n' > $@
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   157
	printf '{\n  global:\n' >> $@
182
b0fbde156bb3 6579436 xf86-video-nv upgrade from 2.0.2 to 2.1.2
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 177
diff changeset
   158
	/usr/ccs/bin/nm -g $(XORGSERVER_BIN) $(PROTODIR)$(X11_SERVERLIBS_DIR)$(ARCHLIBSUBDIR)/libXfont.so | grep -v UNDEF | sed -n -e 's/^.*\|FUNC \|GLOB \|.*\|\([A-Za-z].*\)$$/    \1 = FUNCTION extern;/p' -e 's/^.*\|OBJT \|GLOB \|.*\|\([A-Za-z].*\)$$/    \1 = DATA extern;/p' >> $@
98
c21b46ed1efd 6489660 Xorg server 7.2 [PSARC 2007/051]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
   159
	printf '};\n' >> $@
908
ee1047befc15 6928167 Integrate X server mdb module into xorg-server build & packages
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
   160
963
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   161
# Fix paths in proto area to match paths in packages / installed systems
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   162
install_fix_paths: install_fix_paths_$(MACH)_$(BUILD_TYPE) install_fix_paths_X
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   163
install_fix_paths_$(MACH)_: $(BUILD_TYPES:%=install_fix_paths_$(MACH)_%)
908
ee1047befc15 6928167 Integrate X server mdb module into xorg-server build & packages
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 907
diff changeset
   164
963
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   165
install_fix_paths_i386_32: install_fix_paths_use_utilities
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   166
install_fix_paths_i386_64: install_fix_paths_remove_utilities
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   167
install_fix_paths_sparc_64: # not needed
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   168
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   169
install_fix_paths_use_utilities: default_install
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   170
	rm -f $(PROTODIR)$(MODULE_PREFIX)/bin/cvt \
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   171
	      $(PROTODIR)$(MODULE_PREFIX)/bin/gtf
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   172
	mv -f $(PROTODIR)$(MODULE_PREFIX)/bin/$(ARCHBINSUBDIR)/cvt \
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   173
	      $(PROTODIR)$(MODULE_PREFIX)/bin/$(ARCHBINSUBDIR)/gtf \
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   174
	      $(PROTODIR)$(MODULE_PREFIX)/bin
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   175
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   176
install_fix_paths_remove_utilities: default_install
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   177
	rm -f $(PROTODIR)$(MODULE_PREFIX)/bin/$(ARCHBINSUBDIR)/cvt \
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   178
	      $(PROTODIR)$(MODULE_PREFIX)/bin/$(ARCHBINSUBDIR)/gtf
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   179
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   180
install_fix_paths_X: default_install
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   181
	rm -f $(PROTODIR)$(MODULE_PREFIX)/bin/X \
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   182
	      $(PROTODIR)$(MODULE_PREFIX)/bin/$(ARCHBINSUBDIR)/X
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   183
	ln -s Xserver $(PROTODIR)$(MODULE_PREFIX)/bin/X
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   184
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   185
XSERVERS = Xorg Xephyr Xvfb
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   186
XSERVER_LINKS = $(XSERVERS:%=$(PROTODIR)$(MODULE_PREFIX)/bin/%)
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   187
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   188
$(PROTODIR)/usr/lib/isaexec:
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   189
	@rm -f $@
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   190
	cp -pf /usr/lib/isaexec $@
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   191
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   192
$(XSERVER_LINKS): $(PROTODIR)/usr/lib/isaexec
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   193
	@rm -f $@
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   194
	ln $(PROTODIR)/usr/lib/isaexec $@
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   195
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   196
install_fix_paths_i386_32: install_fix_paths_Xservers_isaexec
7a4fced80e83 6962316 X proto area should more closely match packages
Alan Coopersmith <Alan.Coopersmith@Oracle.COM>
parents: 952
diff changeset
   197
install_fix_paths_Xservers_isaexec: $(XSERVER_LINKS)