usr/src/lib/libpcap/Makefile.sfw
author Cyril Plisko <cyril.plisko@grigale.com>
Sun, 09 May 2010 20:32:17 -0700
changeset 13 971008b98b79
parent 3 ad3552f8e1ef
child 54 c8df60226931
permissions -rw-r--r--
Import sfw build 139 Bugs Fixed ---------- 6839908 dlopen(pkcs11_kernel) and calling C_Initialize makes pkcs11 engine enter infinite loop 6937593 Upgrade LCMS to 1.19 6944247 getifaddrs in 137 breaks sfw build
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
     1
#
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
     2
# CDDL HEADER START
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
     3
#
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
     4
# The contents of this file are subject to the terms of the
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
     5
# Common Development and Distribution License (the "License").
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
     6
# You may not use this file except in compliance with the License.
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
     7
#
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
     8
# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
     9
# or http://www.opensolaris.org/os/licensing.
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    10
# See the License for the specific language governing permissions
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    11
# and limitations under the License.
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    12
#
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    13
# When distributing Covered Code, include this CDDL HEADER in each
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    14
# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    15
# If applicable, add the following below this CDDL HEADER, with the
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    16
# fields enclosed by brackets "[]" replaced with your own identifying
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    17
# information: Portions Copyright [yyyy] [name of copyright owner]
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    18
#
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    19
# CDDL HEADER END
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    20
#
13
971008b98b79 Import sfw build 139
Cyril Plisko <cyril.plisko@grigale.com>
parents: 3
diff changeset
    21
# Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved.
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    22
#
13
971008b98b79 Import sfw build 139
Cyril Plisko <cyril.plisko@grigale.com>
parents: 3
diff changeset
    23
971008b98b79 Import sfw build 139
Cyril Plisko <cyril.plisko@grigale.com>
parents: 3
diff changeset
    24
#ident	"@(#)Makefile.sfw	1.4	10/04/15 SMI"
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    25
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    26
include ../Makefile.lib
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    27
3
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    28
VER=libpcap-1.0.0
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    29
VER64=$(VER)-64
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    30
TARBALL =	$(VER).tar.gz
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    31
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    32
# Common environment variables
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    33
MAKE=$(GMAKE)
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    34
TARGET_COMENV +=	INSTALL=/usr/bin/ginstall
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    35
TARGET_COMENV +=	PATH="$(SFW_PATH)"
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    36
TARGET_COMENV +=	MAKE="$(GMAKE)"
3
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    37
TARGET_COMENV +=	LIBS="$(LIBS)"
13
971008b98b79 Import sfw build 139
Cyril Plisko <cyril.plisko@grigale.com>
parents: 3
diff changeset
    38
TARGET_COMENV +=	"ac_cv_func_getifaddrs=no"
3
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    39
PATCHES:sh =		echo Patches/*.patch
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    40
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    41
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    42
# environment variables for 32-bit
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    43
TARGET_ENV +=	CC="$(CC)"
3
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    44
TARGET_ENV += CFLAGS="$(CFLAGS) -I. -xstrconst $($(MACH)_C_PICFLAGS) -DHAVE_CONFIG_H -D_U_="""
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    45
TARGET_ENV +=	$(TARGET_COMENV)
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    46
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    47
TARGET_ENV64 +=	CFLAGS="$(CFLAGS64) -I. -xstrconst $($(MACH64)_C_PICFLAGS) \
3
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    48
	-DHAVE_CONFIG_H -D_U_="""
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    49
TARGET_ENV64 +=	CC="$(CC64)"
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    50
TARGET_ENV64 +=	$(TARGET_COMENV)
3
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    51
CONFIGURE_OPTIONS +=	--enable-ipv6
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    52
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    53
CFGMAN3PCAP =		$(CFGMAN)/man3pcap
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    54
ROOTMAN3PCAP =		$(ROOT)$(CFGMAN3PCAP)
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    55
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    56
all : all32 all64
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    57
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    58
all32: $(VER)/config.status
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    59
	(cd $(VER); env $(TARGET_ENV) $(MAKE) shared) 
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    60
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    61
all64: $(VER64)/config.status
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    62
	(cd $(VER64); env $(TARGET_ENV64) $(MAKE) shared)
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    63
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    64
install: all
3
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    65
	mkdir -m 755 -p $(ROOTINCLUDE) $(ROOTINCLUDE)/pcap
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    66
	for i in $(ROOT) $(ROOT)$(CFGPREFIX) $(ROOT)$(CFGPREFIX)/share \
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    67
	    $(ROOT)$(CFGMAN) $(ROOTMAN3PCAP); do \
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    68
		mkdir -m 755 -p $$i; \
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    69
	done
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    70
	ROOTLIB=$(ROOTLIB) ROOTINCLUDE=$(ROOTINCLUDE) ROOTMAN3PCAP=$(ROOTMAN3PCAP) $(SH) ./install-sfw
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    71
	ROOTLIB64=$(ROOTLIB64) MACH64=$(MACH64) $(SH) ./install-sfw-64
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    72
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    73
real-all: all32 all64
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    74
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    75
$(VER)/config.status: $(VER)/configure
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    76
	(cd $(VER); "/usr/bin/autoconf"; env $(TARGET_ENV) \
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    77
	    ./configure $(CONFIGURE_OPTIONS))
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    78
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    79
# Running 'autoconf' as configure.in has been patched. 
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    80
$(VER64)/config.status: $(VER64)/configure
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    81
	(cd $(VER64); "/usr/bin/autoconf"; env $(TARGET_ENV64) \
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    82
	    ./configure $(CONFIGURE_OPTIONS))
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    83
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    84
# Running 'autoheader' as configure.in has been patched. 
3
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    85
$(VER)/configure: $(VER)/.patched
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    86
	(cd $(VER);"/usr/bin/autoheader";)
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    87
3
ad3552f8e1ef Import sfw build 129
Cyril Plisko <cyril.plisko@grigale.com>
parents: 0
diff changeset
    88
$(VER64)/configure: $(VER64)/.patched
0
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    89
	(cd $(VER64);"/usr/bin/autoheader";)
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    90
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    91
clean:
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    92
	-rm -rf $(VER)
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    93
	-rm -rf $(VER64)
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    94
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    95
install_h:
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    96
b34509ac961f Import sfw repo b126
Cyril Plisko <cyril.plisko@grigale.com>
parents:
diff changeset
    97
include ../Makefile.targ