aboutsummaryrefslogtreecommitdiff
path: root/databases/linux-oracle-instantclient-basic/Makefile
blob: 8573fa332ed236eda584abc9447465d35cb15500 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# Created by: Alexander Novitsky
# $FreeBSD$

PORTNAME=		instantclient
PORTVERSION=		${ORACLEVERSION}.${DISTDATE}
PORTREVISION=		2
CATEGORIES=		databases
MASTER_SITES=		#http://www.oracle.com/technology/software/tech/oci/instantclient/
PKGNAMEPREFIX=		linux-oracle-
PKGNAMESUFFIX=		-basic
DISTNAME=		${PORTNAME}${PKGNAMESUFFIX}-${LINUXARCH}-${ORACLEVERSION}-${DISTDATE}
DIST_SUBDIR=		oracle

MAINTAINER=		ports@FreeBSD.org
COMMENT=		Oracle 10 InstantClient basics. Works with Oracle RDBMS 8.1.2+

ONLY_FOR_ARCHS=		i386	# amd64(not yet on own)
NO_BUILD=		yes
DISTINFO_FILE=		${MASTERDIR}/distinfo.${ARCH}

RESTRICTED=		Packaging prohibited by Oracle license

USES=			zip
USE_LINUX=		yes
USE_LINUX_PREFIX=	yes

ORACLEVERSION=		10.2.0.3

BINS_LIST=		genezi

LIBS_LIST=		libclntsh.so.10.1	\
			libnnz10.so		\
			libocci.so.10.1		\
			libociei.so		\
			libocijdbc10.so		\
			ojdbc14.jar

WRKSRC=			${WRKDIR}/instantclient_10_2

INSTBINSDIR=		${PREFIX}/usr/lib/oracle/${ORACLEVERSION}/client/bin
INSTLIBSDIR=		${PREFIX}/usr/lib/oracle/${ORACLEVERSION}/client/lib

PLIST_SUB=		ORACLEVERSION=${ORACLEVERSION}

NO_STAGE=	yes
.include <bsd.port.pre.mk>

.if		${ARCH} == "i386"
LINUXARCH=		linux32
DISTDATE=		20061115
.elif		${ARCH} == "amd64"
LINUXARCH=		linux-x86-64
DISTDATE=		20070103
.endif

.if !exists(${DISTDIR}/${DIST_SUBDIR}/${DISTNAME}${EXTRACT_SUFX})
ECHO_MSG=		${PRINTF} %b

IGNORE+=		\n\n-=< MARKED AS IGNORED: >=-\n
IGNORE+=		\n
IGNORE+=		Due to Oracle license restrictions, you must fetch the source \n
IGNORE+=		distribution manually.  Please access  \n
IGNORE+=		http://www.oracle.com/technology/software/tech/oci/instantclient/index.html \n
IGNORE+=		with a web browser and follow the link for the \n
IGNORE+=		"${DISTFILES}".  \n
IGNORE+=		You will be required to register and log in, \n
IGNORE+=		but you can create an account on that page.  \n
IGNORE+=		After registration and accepting the Oracle License, \n
IGNORE+=		download the distribution file, \n ${DISTFILES}, \n
IGNORE+=		into ${DISTDIR}/${DIST_SUBDIR}/ \n
IGNORE+=		and then restart this installation\n\n
.endif

do-install:
			@${MKDIR} -m 0755 ${INSTBINSDIR}
			@${MKDIR} -m 0755 ${INSTLIBSDIR}
.for i in ${BINS_LIST}
			${INSTALL_DATA} ${WRKSRC}/${i} ${INSTBINSDIR}/${i}
.endfor
.for i in ${LIBS_LIST}
			${INSTALL_DATA} ${WRKSRC}/${i} ${INSTLIBSDIR}/${i}
.endfor
			${ECHO_CMD} "${INSTLIBSDIR:S,${PREFIX},,}" >> ${PREFIX}/etc/ld.so.conf
			${PREFIX}/sbin/ldconfig

.include <bsd.port.post.mk>