open-src/lib/Makefile.inc
author Alan Coopersmith <Alan.Coopersmith@Sun.COM>
Tue, 14 Jul 2009 10:27:59 -0700
changeset 747 fd7c3789a134
parent 705 24ca414edbff
child 810 6f94d3da0552
permissions -rw-r--r--
6860365 Remove lg3d library and headers
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
87
f16a51e60f1c 6504462 XFixes 4.0 [PSARC 2006/702]
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 70
diff changeset
     1
# -*- Makefile -*- rules common to most X.Org library modules
70
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     2
#
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: 591
diff changeset
     3
# Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
70
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     4
# Use subject to license terms.
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     5
#
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     6
# Permission is hereby granted, free of charge, to any person obtaining a
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     7
# copy of this software and associated documentation files (the
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     8
# "Software"), to deal in the Software without restriction, including
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
     9
# without limitation the rights to use, copy, modify, merge, publish,
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    10
# distribute, and/or sell copies of the Software, and to permit persons
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    11
# to whom the Software is furnished to do so, provided that the above
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    12
# copyright notice(s) and this permission notice appear in all copies of
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    13
# the Software and that both the above copyright notice(s) and this
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    14
# permission notice appear in supporting documentation.
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    15
# 
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    16
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    17
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    18
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    19
# OF THIRD PARTY RIGHTS. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    20
# HOLDERS INCLUDED IN THIS NOTICE BE LIABLE FOR ANY CLAIM, OR ANY SPECIAL
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    21
# INDIRECT OR CONSEQUENTIAL DAMAGES, OR ANY DAMAGES WHATSOEVER RESULTING
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    22
# FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    23
# NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    24
# WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    25
# 
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    26
# Except as contained in this notice, the name of a copyright holder
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    27
# shall not be used in advertising or otherwise to promote the sale, use
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    28
# or other dealings in this Software without prior written authorization
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    29
# of the copyright holder.
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    30
#
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: 591
diff changeset
    31
# @(#)Makefile.inc	1.13	09/05/15
70
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    32
#
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    33
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    34
PWD:sh=pwd
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    35
TOP=$(PWD)/../..
156
1dec9ce4addc 6551329 X open-src makefiles spawn too many shell commands
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 87
diff changeset
    36
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    37
MODTYPE=lib
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    38
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    39
### Include common definitions
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    40
include $(TOP)/common/Makefile.init
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    41
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    42
# Set default to build both 32-bit & 64-bit if not set in module makefile
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    43
BUILD_TYPES_DEFAULT     = $(BUILD_TYPES_SET:yes=$(POUND_SIGN))
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    44
$(BUILD_TYPES_DEFAULT)  BUILD_TYPES=32 64
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    45
$(BUILD_TYPES_DEFAULT)	BUILD_TYPES_SET=yes
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    46
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    47
# Changes to apply to man pages
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    48
MODULE_MTLEVEL_DEFAULT	= $(MODULE_MTLEVEL_SET:yes=$(POUND_SIGN))
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    49
$(MODULE_MTLEVEL_DEFAULT)	MODULE_MTLEVEL=See XInitThreads(3X11)
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    50
MODTYPE_SUNTOUCH_MAN_FLAGS= -l $(LIBNAME) -a '{MT-Level, $(MODULE_MTLEVEL)}'
70
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    51
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    52
# Flags to build & link libraries with
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    53
MODTYPE_CPPFLAGS=$(LIB_CPPFLAGS)
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    54
MODTYPE_CFLAGS=$(LIB_CFLAGS)
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: 591
diff changeset
    55
MODTYPE_CXXFLAGS=$(LIB_CXXFLAGS)
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    56
MODTYPE_LDFLAGS=$(LIB_LDFLAGS) -lc
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    57
MODTYPE_LD_OPTIONS=$(LIB_REQUIRED_LDFLAGS)
70
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    58
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    59
# Additional command line options to GNU autoconf configure script
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    60
MODTYPE_CONFIG_OPTS = --enable-shared=yes --enable-static=no \
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    61
    --with-lint --enable-lint-library --with-pic \
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    62
    --libdir='$${exec_prefix}/lib$(MODULE_ADD_LIB_SUBDIR)$(ARCHLIBSUBDIR)' \
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    63
    --bindir='$${exec_prefix}/bin$(ARCHLIBSUBDIR)'
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    64
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    65
# Additional environment variables to GNU autoconf configure script
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    66
MODTYPE_CONFIG_ENV = LIB_MAN_SUFFIX=$(LIB_MAN_SUFFIX)
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    67
591
a2c6b61a92aa 6777135 X builds should record version info in ELF comments
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 493
diff changeset
    68
# Set comments in ELF binaries to help identify versions/builds
a2c6b61a92aa 6777135 X builds should record version info in ELF comments
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 493
diff changeset
    69
MODTYPE_ADD_BUILD_TARGETS=set-elf-comments
a2c6b61a92aa 6777135 X builds should record version info in ELF comments
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 493
diff changeset
    70
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    71
# Additional arguments to pass to make when running make install
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    72
MODTYPE_INSTALL_MAKEFLAGS = \
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    73
	libdir=$(MODULE_PREFIX)/lib$(MODULE_ADD_LIB_SUBDIR)$(ARCHLIBSUBDIR)
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    74
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    75
# Need to fix libtool interference with our linker flags
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    76
DELIBTOOLIZE=yes
70
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    77
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    78
include $(TOP)/common/Makefile.inc
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    79
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    80
# Make 64-bit link when installing 64-bit libraries
70
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    81
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    82
LIB_INST_DIR=$(PROTODIR)$(MODULE_PREFIX)/lib$(MODULE_ADD_LIB_SUBDIR)
292
0cadb6330f7c 6652947 Bold font emulation in Xft is disabled after nevada b80
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 278
diff changeset
    83
493
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    84
install_64::
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    85
	-/bin/rm -f $(LIB_INST_DIR)/64
f43507b5737d 6735203 open-src Makefile cleanup & enhancements
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents: 341
diff changeset
    86
	ln -s $(SUBDIR64) $(LIB_INST_DIR)/64
70
af1bea13b32b 6477401 Xorg modularization: SUNWxorg-client*
Alan Coopersmith <Alan.Coopersmith@Sun.COM>
parents:
diff changeset
    87