summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 444de8081bcdf22e82cd78f267c9dd438b58dda4 (plain)
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
# Contributor: Adam Nielsen <malvineous@shikadi.net>
# Contributor: Vitaliy Berdinskikh <skipper13@archlinux.org.ua>
# Contributor: Andrea Agosti <cifvts@gmail.com>
# Contributor: Viliam Pucik <viliam.pucik@gmail.com>
# Maintainer: Adam Nielsen <malvineous@shikadi.net>

_pkgname=instantclient-odbc
pkgname=oracle-${_pkgname}
pkgver=23.5.0.24.07
_pkgver_vendor_suffix=
_urlver=2350000
_unzippath=instantclient_23_5
pkgrel=1
pkgdesc="Additional libraries for enabling ODBC applications with Instant Client"
arch=('x86_64')
url="https://www.oracle.com/at/database/technologies/instant-client/downloads.html"
license=('custom:OTN')
depends=(oracle-instantclient-basic=$pkgver)
replaces=('instantclient-odbc')
options=(!strip)

source=("https://download.oracle.com/otn_software/linux/instantclient/${_urlver}/${_pkgname}-linux.x64-${pkgver}${_pkgver_vendor_suffix}.zip")
md5sums=('5df518c213dc6756170bd939254010db')
sha256sums=('0f07e149c1badf882380e45f18814860002c041f1912a31be9b4bebca833b7eb')

package() {
	local basedir="$srcdir/${_unzippath}"

	install -d "$pkgdir/usr/lib"
	# Copy files but not symlinks
	install -m 755 -t "$pkgdir/usr/lib" `find "$basedir" -type f -name '*.so*'`

	install -d "$pkgdir/usr/share/oracle"
	install -m 755 -t "$pkgdir/usr/share/oracle" "$basedir/"*.sh

	install -d "$pkgdir/usr/share/doc/oracle"
	install -m 644 -t "$pkgdir/usr/share/doc/oracle" "$basedir/"*README*

	install -Dm644 -t "$pkgdir/usr/share/licenses/$pkgname" "$basedir/"*LICENSE

	# create required symlinks
	cd "$pkgdir/usr/lib" || return 1
	local lib link
	for lib in *.so*; do
		link=$lib
		while [[ ${link#*.} != so ]]; do
			link=${link%.*}
			ln -s $lib $link
		done
	done

}