File: Makefile

package info (click to toggle)
jpilot 0.99.2-2
  • links: PTS
  • area: main
  • in suites: woody
  • size: 3,808 kB
  • ctags: 1,967
  • sloc: ansic: 29,655; sh: 8,387; makefile: 352; sed: 93
file content (72 lines) | stat: -rw-r--r-- 1,779 bytes parent folder | download
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
top_srcdir = ..
top_builddir = ..

# Install variables
prefix=/usr

#Pilot flags (include dir), and Libraries
PILOT_FLAGS= -I/usr/include/libpisock
PILOT_LIBS=-L/usr/lib -lpisock

#opensll or des
CRYPTO_LIBS=-lcrypto

#set CC to your compiler
CC = gcc
INSTALL = /usr/bin/install -c
LIBTOOL = $(SHELL) $(top_builddir)/libtool

# CC options
CCDEFINES = -DHAVE_CONFIG_H
CFLAGS = 
OPTIONS = -Wall -O2 $(CFLAGS)

# GTK+ flags
GTKFLAGS = -I/usr/include/gtk-1.2 -I/usr/include/glib-1.2 -I/usr/lib/glib/include -I/usr/X11R6/include
# GTK+ libs
GTKLIBS = -L/usr/lib -L/usr/X11R6/lib -lgtk -lgdk -rdynamic -lgmodule -lglib -ldl -lXi -lXext -lX11 -lm

# Targets
all: libplugin.h keyring.o libkeyring.la

libkeyring.la: keyring.o
	$(LIBTOOL) --mode=link \
	$(CC) $(OPTIONS) -o libkeyring.la \
	keyring.lo \
	-rpath $(prefix)/lib/jpilot/plugins \
	-version-info 1:1 \
	-avoid-version \
	$(CRYPTO_LIBS)

keyring.o: keyring.c libplugin.h
	$(LIBTOOL) --mode=compile \
	$(CC) $(OPTIONS) $(GTKFLAGS) $(PILOT_FLAGS) -c keyring.c

libplugin.h: ../libplugin.h
	rm -f libplugin.h; ln -s ../libplugin.h libplugin.h; \

clean: 
	rm -f *.o *~ config.cache .libs/* *.so *.so.? *.so.?.? *.lo *.la
	rm -rf .libs/

distclean: clean
	rm -f config.status config.log *.so Makefile

#
# This is a global install.  You can also install per user in
# ~/.jpilot/plugins
#
install:
	$(INSTALL) -d -m 755 $(prefix)/lib/jpilot; \
	$(INSTALL) -d -m 755 $(prefix)/lib/jpilot/plugins; \
	$(LIBTOOL) --mode=install $(INSTALL) \
	libkeyring.la $(prefix)/lib/jpilot/plugins

local_install:
	$(INSTALL) -d -m 755 $(HOME)/.jpilot; \
	$(INSTALL) -d -m 755 $(HOME)/.jpilot/plugins; \
	$(LIBTOOL) --mode=install ./install-sh \
	libkeyring.la $(HOME)/.jpilot/plugins

uninstall:
	rm -f $(prefix)/lib/jpilot/plugins/libkeyring.so*