ObjPgSQL  Check-in [58715a7dc6]

Overview
Comment:Add "make install".
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 58715a7dc63d40149f085a5922893964e5031050eb065fb34179e49b9c68c9e9
User & Date: js on 2012-10-03 16:04:29
Other Links: manifest | tags
Context
2012-10-03
16:08
Add ObjPgSQL.h. check-in: 9b7427552b user: js tags: trunk
16:04
Add "make install". check-in: 58715a7dc6 user: js tags: trunk
13:20
Initial import. check-in: de46b0e10c user: js tags: trunk
Changes

Modified Makefile from [5bed738e9c] to [b6aad65bed].





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











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
+
+
+
+






+
+
+
+
+
+
+
+
+
+
+
+
+
+






-
-
+
+
-






-
-


+





+
+
+
+
+
+
+
+
+
+
+
LIB = objpgsql
LIB_MAJOR = 0
LIB_MINOR = 0

SRCS = PGConnection.m				\
       PGResult.m				\
       PGResultRow.m				\
       exceptions/PGCommandFailedException.m	\
       exceptions/PGConnectionFailedException.m	\
       exceptions/PGException.m
HEADERS = ${SRCS:.m=.h}

CPPFLAGS += -Wall -Iexceptions -I.
LIBS += -lpq

prefix ?= /usr/local

INSTALL ?= install
OBJFW_CONFIG ?= objfw-config
OBJFW_COMPILE ?= objfw-compile

LIB_PREFIX = `${OBJFW_CONFIG} --lib-prefix`
LIB_SUFFIX = `${OBJFW_CONFIG} --lib-suffix`
LIB_FILE = ${LIB_PREFIX}${LIB}${LIB_SUFFIX}

all:
	@objfw-compile			\
		--lib 0.0		\
		-o objpgsql		\
		--builddir build	\
		-Iexceptions		\
		-I.			\
		${CPPFLAGS}		\
		${LIBS}			\
		-lpq			\
		${SRCS}

test:
	@objfw-compile			\
		-o test			\
		--builddir build	\
		-Iexceptions		\
		-I.			\
		-L.			\
		-lobjpgsql		\
		${CPPFLAGS}		\
		test.m

clean:
	rm -f libobjpgsql.* exceptions/*~ *~
	rm -fr build

install:
	mkdir -p ${destdir}${prefix}/include/ObjPgSQL/exceptions
	for i in ${HEADERS}; do \
		${INSTALL} -m 644 $$i \
			${destdir}${prefix}/include/ObjPgSQL/$$i; \
	done
	mkdir -p ${destdir}${prefix}/lib
	export LIB_MAJOR=${LIB_MAJOR}; \
	export LIB_MINOR=${LIB_MINOR}; \
	${INSTALL} -m 755 ${LIB_FILE} ${destdir}${prefix}/lib/${LIB_FILE}