summaryrefslogtreecommitdiff
path: root/databases/xmysql/patches/patch-aa
blob: 7d10b0183a58c213ede8939523a9b174b4dbdc5e (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
53
54
55
56
57
58
59
60
61
62
$NetBSD: patch-aa,v 1.3 2002/04/17 04:45:10 fredb Exp $

--- Makefile.orig	Tue Nov 17 22:19:06 1998
+++ Makefile
@@ -31,24 +31,24 @@
 PROGRAM = 	xmysql
 
 # PROGRAM install path
-INSTALLPATH = /usr/local/xmysql-1.10
+INSTALLPATH = ${PREFIX}/bin
 
 # pixmap location
-XMYSQL_XPMPATH = /usr/local/xmysql-1.10
+XMYSQL_XPMPATH = ${PREFIX}/share/xmysql
 
 # help path
-XMYSQL_HELPPATH = /usr/local/xmysql-1.10
+XMYSQL_HELPPATH = ${PREFIX}/share/xmysql
 
 # Compilation Details
-CC = gcc
+CC = cc
 STDCFLAGS = -g -c -O2 -Wall -DXMYSQL_XPMPATH=\"$(XMYSQL_XPMPATH)\" -DXMYSQL_HELPPATH=\"$(XMYSQL_HELPPATH)\"
-STDLFLAGS = 
-MYSQLINC = -I/usr/include/mysql
-MYSQLLOAD = -L/usr/lib/mysql -lmysqlclient
-XFORMLIBDIR = -L/usr/local/xforms
-XFORMINCDIR = -I/usr/local/xforms
-XINC = 
-XLOAD = -L/usr/X11R6/lib  -lX11
+STDLFLAGS = ${LDFLAGS}
+MYSQLINC = -I${PREFIX}/include/mysql
+MYSQLLOAD = -Wl,-R${PREFIX}/lib/mysql -L${PREFIX}/lib/mysql -lmysqlclient
+XFORMLIBDIR = -L${LOCALBASE}/lib -Wl,-R${LOCALBASE}/lib
+XFORMINCDIR = -I${X11PREFIX}/include/X11
+XINC = -I${X11BASE}/include
+XLOAD = -lX11
 
 # objects needed for the program
 OBJS =  Xmysql.o \
@@ -60,7 +60,7 @@
 ${PROGRAM}: $(OBJS)
 	$(CC) -o ${PROGRAM} $(OBJS) $(MYSQLINC) $(XFORMINCDIR) \
 	$(XINC) $(STDLFLAGS) $(MYSQLLOAD) \
-	$(XLOAD) $(XFORMLIBDIR) -lforms -lXpm -lm
+	$(XLOAD) $(XFORMLIBDIR) -lforms -ljpeg -lXpm -lm
 
 .c.o:
 	$(CC) $*.c $(STDCFLAGS) $(XFORMINCDIR) $(MYSQLINC) $(XINC)
@@ -69,8 +69,8 @@
 	rm -f ${PROGRAM} $(OBJS) 
 
 install:
-	install -d $(INSTALLPATH) $(XMYSQL_XPMPATH) $(XMYSQL_HELPPATH)
-	install --mode=711 $(PROGRAM) $(INSTALLPATH)
-	install --mode=744 mysql.xpm $(XMYSQL_XPMPATH)
-	install --mode=744 sqlhelp.txt $(XMYSQL_HELPPATH) 
+	${BSD_INSTALL_DATA_DIR} -d $(XMYSQL_XPMPATH) $(XMYSQL_HELPPATH)
+	${BSD_INSTALL_PROGRAM} $(PROGRAM) $(INSTALLPATH)
+	${BSD_INSTALL_DATA} mysql.xpm $(XMYSQL_XPMPATH)
+	${BSD_INSTALL_DATA} sqlhelp.txt $(XMYSQL_HELPPATH)