comparison src/postgresql.mk @ 527:6f7fcfe88cf3

new package: postgresql (by Mark Brand)
author Volker Grabsch <vog@notjusthosting.com>
date Mon, 09 Nov 2009 02:13:41 +0100
parents
children cc31dacda67d
comparison
equal deleted inserted replaced
526:4dc869999594 527:6f7fcfe88cf3
1 # Copyright (C) 2009 Mark Brand
2 # Volker Grabsch
3 #
4 # Permission is hereby granted, free of charge, to any person obtaining
5 # a copy of this software and associated documentation files (the
6 # "Software"), to deal in the Software without restriction, including
7 # without limitation the rights to use, copy, modify, merge, publish,
8 # distribute, sublicense, and/or sell copies of the Software, and to
9 # permit persons to whom the Software is furnished to do so, subject
10 # to the following conditions:
11 #
12 # The above copyright notice and this permission notice shall be
13 # included in all copies or substantial portions of the Software.
14 #
15 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16 # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17 # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
18 # IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
19 # CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
20 # TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
21 # SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
23 # PostgreSQL
24 PKG := postgresql
25 $(PKG)_IGNORE :=
26 $(PKG)_VERSION := 8.4.1
27 $(PKG)_CHECKSUM := e6903f0029402ef8fb12645a177204499ea5b2b7
28 $(PKG)_SUBDIR := postgresql-$($(PKG)_VERSION)
29 $(PKG)_FILE := postgresql-$($(PKG)_VERSION).tar.bz2
30 $(PKG)_WEBSITE := http://www.postgresql.org/
31 $(PKG)_URL := http://ftp2.nl.postgresql.org/source/v$($(PKG)_VERSION)/$($(PKG)_FILE)
32 $(PKG)_URL_2 := http://ftp10.us.postgresql.org/postgresql/source/v$($(PKG)_VERSION)/$($(PKG)_FILE)
33 $(PKG)_DEPS := gcc zlib
34
35 define $(PKG)_UPDATE
36 wget -q -O- 'http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/' | \
37 grep '<option>REL' | \
38 $(SED) -n 's,.*REL\([0-9][0-9_]*\)<.*,\1,p' | \
39 $(SED) 's,_,.,g' | \
40 head -1
41 endef
42
43 define $(PKG)_BUILD
44 # Since we build only client libary, use bogus tzdata to satisfy configure.
45 # We have to build the shared library, but we won't install it.
46 cd '$(1)' && ./configure \
47 --prefix='$(PREFIX)/$(TARGET)' \
48 --host='$(TARGET)' \
49 --disable-rpath \
50 --without-readline \
51 --with-zlib \
52 --with-system-tzdata=/dev/null
53 $(MAKE) -C '$(1)'/src/interfaces/libpq -j '$(JOBS)'
54 $(MAKE) -C '$(1)'/src/interfaces/libpq -j '$(JOBS)' install enable_shared=no
55 $(INSTALL) -m664 '$(1)/src/include/pg_config.h' '$(PREFIX)/$(TARGET)/include/'
56 $(INSTALL) -m664 '$(1)/src/include/postgres_ext.h' '$(PREFIX)/$(TARGET)/include/'
57 endef