tools/Makefile
author Mike Sullivan <Mike.Sullivan@Oracle.COM>
Sat, 24 Sep 2016 09:29:15 -0700
changeset 6971 32152bc508b7
parent 6132 7fb35b7d3c4d
child 7104 8f45af4c27d7
permissions -rw-r--r--
Close of build 109.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
9
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
     1
#
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
     2
# CDDL HEADER START
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
     3
#
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
     7
#
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
     8
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    11
# and limitations under the License.
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    12
#
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    14
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    18
#
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    19
# CDDL HEADER END
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    20
#
5682
94c0ca64c022 15558602 TCL_LD_SEARCH_FLAGS is wrongly defined in tclConfig.sh
Shawn Walker-Salas <shawn.walker@oracle.com>
parents: 5569
diff changeset
    21
94c0ca64c022 15558602 TCL_LD_SEARCH_FLAGS is wrongly defined in tclConfig.sh
Shawn Walker-Salas <shawn.walker@oracle.com>
parents: 5569
diff changeset
    22
#
5508
3b7bb04ece74 22821402 Userland build doesn't need GCC3 references any more.
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 2204
diff changeset
    23
# Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved.
9
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    24
#
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    25
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    26
include ../make-rules/shared-macros.mk
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    27
774
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 16
diff changeset
    28
download setup prep build install publish \
5569
c3326e2b8b45 backout 22351416/22330374 - needs more work
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 5565
diff changeset
    29
validate:	links pkglint time-$(MACH32).so time-$(MACH64).so
774
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 16
diff changeset
    30
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 16
diff changeset
    31
# generate wrappers for parfait. we need to generate them
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 16
diff changeset
    32
# with the correct compiler variables from the common makefiles because
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 16
diff changeset
    33
# some things reset the environment which causes lovely infinite
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 16
diff changeset
    34
# loops
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 16
diff changeset
    35
links:
1394
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1352
diff changeset
    36
	@$(MKDIR) $(PARFAIT_TOOLS)
774
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 16
diff changeset
    37
	@for i in cc CC gcc g++ ld ; do \
1394
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1352
diff changeset
    38
		$(RM) $(PARFAIT_TOOLS)/$$i ; \
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1352
diff changeset
    39
		echo "#!/bin/ksh" > $(PARFAIT_TOOLS)/$$i ; \
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1352
diff changeset
    40
		echo "IFS=" >> $(PARFAIT_TOOLS)/$$i ; \
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1352
diff changeset
    41
		echo "export PARFAIT_NATIVESUNCC=$(SPRO_VROOT)/bin/cc" >> $(PARFAIT_TOOLS)/$$i ; \
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1352
diff changeset
    42
		echo "export PARFAIT_NATIVESUNCXX=$(SPRO_VROOT)/bin/CC" >> $(PARFAIT_TOOLS)/$$i ; \
2204
f83e0e3cf2d7 20010352 userland should move to parfait 1.5.1
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1645
diff changeset
    43
		echo "export PARFAIT_NATIVEGCC=$(GCC_ROOT)/bin/gcc" >> $(PARFAIT_TOOLS)/$$i ; \
f83e0e3cf2d7 20010352 userland should move to parfait 1.5.1
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1645
diff changeset
    44
		echo "export PARFAIT_NATIVEGXX=$(GCC_ROOT)/bin/g++" >> $(PARFAIT_TOOLS)/$$i ; \
1394
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1352
diff changeset
    45
		echo "export PARFAIT_NATIVELD=/usr/bin/ld" >> $(PARFAIT_TOOLS)/$$i ; \
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1352
diff changeset
    46
		echo "exec" $(PARFAIT_ROOT)/$(MACH)/parfait-$$i '$$*' >> $(PARFAIT_TOOLS)/$$i ; \
5f86498eee95 16991973 some things ain't parfait'n
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 1352
diff changeset
    47
		chmod +x $(PARFAIT_TOOLS)/$$i ; \
774
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 16
diff changeset
    48
	done
d0cbca26a17c 7035978 parfait support for userland bits
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 16
diff changeset
    49
1188
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    50
pkglint:
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    51
	@rm -f pkglint
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    52
	@sed -e "s,WS_TOP_XXX,$(WS_TOP)/$(MACH)," \
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    53
	    < pkglint.sh \
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    54
	    > pkglint
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    55
	@chmod +x pkglint
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    56
16
33aaaec59991 update _DATE/_TIME compiler chatter reduction bits.
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents: 9
diff changeset
    57
33aaaec59991 update _DATE/_TIME compiler chatter reduction bits.
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents: 9
diff changeset
    58
time-$(MACH64).o:			BITS=64
33aaaec59991 update _DATE/_TIME compiler chatter reduction bits.
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents: 9
diff changeset
    59
time-$(MACH32).o time-$(MACH64).o:	CFLAGS += -Kpic
33aaaec59991 update _DATE/_TIME compiler chatter reduction bits.
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents: 9
diff changeset
    60
33aaaec59991 update _DATE/_TIME compiler chatter reduction bits.
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents: 9
diff changeset
    61
time-$(MACH32).o time-$(MACH64).o:	time.c
1188
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    62
	@$(CC) $(CFLAGS) -c -o [email protected] $<
9
97fb557d9979 lcms download link has changed
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents:
diff changeset
    63
16
33aaaec59991 update _DATE/_TIME compiler chatter reduction bits.
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents: 9
diff changeset
    64
time-%.so:	time-%.o
1188
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    65
	@$(LD) -G -o [email protected] $<
16
33aaaec59991 update _DATE/_TIME compiler chatter reduction bits.
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents: 9
diff changeset
    66
33aaaec59991 update _DATE/_TIME compiler chatter reduction bits.
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents: 9
diff changeset
    67
clean:
1188
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    68
	@$(RM) time-*.o time*.bc
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    69
	@$(RM) pkglint
16
33aaaec59991 update _DATE/_TIME compiler chatter reduction bits.
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents: 9
diff changeset
    70
33aaaec59991 update _DATE/_TIME compiler chatter reduction bits.
Norm Jacobs <Norm.Jacobs@Sun.COM>
parents: 9
diff changeset
    71
clobber:	clean
1188
d563dccb5adb 16404201 serialize pkglinting of components
Mike Sullivan <Mike.Sullivan@Oracle.COM>
parents: 975
diff changeset
    72
	@$(RM) time-*.so python/pkglint/*.pyc
5508
3b7bb04ece74 22821402 Userland build doesn't need GCC3 references any more.
Norm Jacobs <Norm.Jacobs@Oracle.COM>
parents: 2204
diff changeset
    73
	@$(RM) -r $(PARFAIT_TOOLS) $(MACH)
6132
7fb35b7d3c4d 20258565 gmake clobber doesn't remove PGP signatures
Danek Duvall <danek.duvall@oracle.com>
parents: 5682
diff changeset
    74
	@$(RM) .gnupg/pubring.gpg~ .gnupg/secring.gpg .gnupg/trustdb.gpg