components/gnupth/Makefile
author Rich Burridge <rich.burridge@oracle.com>
Mon, 05 Dec 2011 11:48:52 -0800
changeset 609 775168282b2f
parent 250 3ec860f369f5
child 800 2ad056ed89ec
permissions -rw-r--r--
7037821 Userland migration of data from Makefile to manifest may have been a little overzealous
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
250
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     1
#
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     2
# CDDL HEADER START
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     3
#
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     7
#
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     8
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    11
# and limitations under the License.
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    12
#
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    14
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    18
#
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    19
# CDDL HEADER END
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    20
#
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    21
# Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved.
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    22
#
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    23
include ../../make-rules/shared-macros.mk
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    24
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    25
COMPONENT_NAME=		pth
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    26
COMPONENT_VERSION=	2.0.7
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    27
COMPONENT_SRC=		$(COMPONENT_NAME)-$(COMPONENT_VERSION)
609
775168282b2f 7037821 Userland migration of data from Makefile to manifest may have been a little overzealous
Rich Burridge <rich.burridge@oracle.com>
parents: 250
diff changeset
    28
COMPONENT_PROJECT_URL=	http://www.gnu.org/software/pth/
250
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    29
COMPONENT_ARCHIVE=	$(COMPONENT_SRC).tar.gz
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    30
COMPONENT_ARCHIVE_HASH=	sha1:9a71915c89ff2414de69fe104ae1016d513afeee
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    31
COMPONENT_ARCHIVE_URL=	http://ftp.gnu.org/gnu/pth/$(COMPONENT_ARCHIVE)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    32
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    33
include ../../make-rules/prep.mk
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    34
include ../../make-rules/configure.mk
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    35
include ../../make-rules/ips.mk
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    36
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    37
PATCH_LEVEL = 0
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    38
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    39
# Enable C99 mode + -Xc for its additional warnings.
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    40
studio_C99MODE = -Xc $(studio_C99_ENABLE)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    41
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    42
# -xinline=%auto -- we like inlining where appropriate
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    43
CFLAGS += -xinline=%auto
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    44
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    45
# -xbuiltin=%none -- builtins have been known to be buggy
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    46
CFLAGS += -xbuiltin=%none
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    47
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    48
CFLAGS += $(CPP_LARGEFILES)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    49
CFLAGS += $(XPG6MODE)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    50
CFLAGS += $(CPP_POSIX)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    51
CFLAGS += $(studio_PIC)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    52
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    53
CPPFLAGS += $(CPP_LARGEFILES) $(CPP_POSIX)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    54
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    55
LDFLAGS =	-lpthread -lposix4 -lrt
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    56
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    57
CONFIGURE_OPTIONS  +=	--localstatedir=/var
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    58
CONFIGURE_OPTIONS  +=	--with-pic
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    59
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    60
CONFIGURE_ENV  +=   CC="$(CC)"
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    61
CONFIGURE_ENV  +=   LD="$(CC) $(CFLAGS) $(LDFLAGS)"
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    62
CONFIGURE_ENV  +=   CFLAGS="$(CFLAGS)"
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    63
CONFIGURE_ENV  +=   CPPFLAGS="$(CPPFLAGS)"
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    64
CONFIGURE_ENV  +=   CPP="$(CC) $(CPPFLAGS) $(CFLAGS) -E"
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    65
CONFIGURE_ENV  +=   LDFLAGS="$(LDFLAGS)"
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    66
CONFIGURE_ENV +=    INSTALL="$(INSTALL)"
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    67
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    68
build: $(BUILD_32_and_64)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    69
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    70
install: $(INSTALL_32_and_64)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    71
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    72
test: $(TEST_32_and_64)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    73
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    74
BUILD_PKG_DEPENDENCIES = $(BUILD_TOOLS)
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    75
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    76
include ../../make-rules/depend.mk
3ec860f369f5 7046183 GNU Pthreads to Userland
Stefan Teleman <stefan.teleman@oracle.com>
parents:
diff changeset
    77