File: Makefile.in

package info (click to toggle)
chrony 1.14-7
  • links: PTS
  • area: main
  • in suites: woody
  • size: 1,480 kB
  • ctags: 2,091
  • sloc: ansic: 15,266; sh: 194; makefile: 113
file content (108 lines) | stat: -rw-r--r-- 3,151 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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
##################################################
#
# $Header: /cvs/src/chrony/Makefile.in,v 1.30 2000/07/24 21:44:44 richard Exp $
#
# =======================================================================
#
# chronyd/chronyc - Programs for keeping computer clocks accurate.
#
# Copyright (C) 1997-1999 Richard P. Curnow
# All rights reserved.
#
# For conditions of use, refer to the file LICENCE.
#
# =======================================================================
#
# Makefile template

INSTALL_PREFIX=@INSTALL_PREFIX@

CC = gcc
CCWARNFLAGS =
#CCWARNFLAGS = -Wmissing-prototypes -Wall
OPTFLAGS = -O2 -g

OBJS = util.o sched.o regress.o local.o \
	sys.o main.o ntp_io.o ntp_core.o ntp_sources.o \
	sources.o sourcestats.o reference.o \
	logging.o conf.o cmdmon.o md5.o keys.o \
	nameserv.o acquire.o manual.o addrfilt.o \
	cmdparse.o mkdirpp.o rtc.o pktlength.o clientlog.o

EXTRA_OBJS=@EXTRA_OBJECTS@

CLI_OBJS = client.o md5.o nameserv.o getdate.o cmdparse.o \
           pktlength.o

SRCS = $(patsubst %.o,%.c,$(OBJS))
EXTRA_SRCS = $(patsubst %.o,%.c,$(EXTRA_OBJS))

CLI_SRCS = $(patsubst %.o,%.c,$(CLI_OBJS))

LIBS = -lm

EXTRA_LIBS=@EXTRA_LIBS@
EXTRA_CLI_LIBS=@EXTRA_CLI_LIBS@

DEFS=@SYSDEFS@

CFLAGS = $(CCWARNFLAGS) $(OPTFLAGS)

# Until we have a main procedure we can link, just build object files
# to test compilation

all : chronyd chronyc

chronyd : $(OBJS) $(EXTRA_OBJS)
	$(CC) $(OPTFLAGS) -o chronyd $(OBJS) $(EXTRA_OBJS) $(LIBS) $(EXTRA_LIBS)

chronyc : $(CLI_OBJS)
	$(CC) $(OPTFLAGS) -o chronyc $(CLI_OBJS) $(LIBS) $(EXTRA_CLI_LIBS)

.depend : 
	gcc -MM $(SRCS) $(EXTRA_SRCS) > .depend

distclean :
	-rm -f *.o *.s chronyc chronyd core options.h Makefile *~

clean :
	-rm -f *.o *.s chronyc chronyd core *~

version.h : version.txt
	sed -e 's/[$$]Name: \(.*\) [$$]/\1/;' < version.txt > version.h


# For install, don't use the install command, because its switches
# seem to vary between systems.

install:
	[ -d $(INSTALL_PREFIX) ] || mkdir $(INSTALL_PREFIX)
	[ -d $(INSTALL_PREFIX)/sbin ] || mkdir $(INSTALL_PREFIX)/sbin
	[ -d $(INSTALL_PREFIX)/bin ] || mkdir $(INSTALL_PREFIX)/bin
	[ -d $(INSTALL_PREFIX)/share/doc ] || mkdir $(INSTALL_PREFIX)/share/doc
	[ -d $(INSTALL_PREFIX)/share/doc/chrony ] || mkdir $(INSTALL_PREFIX)/share/doc/chrony
	cp chronyd $(INSTALL_PREFIX)/sbin/chronyd
	chown root $(INSTALL_PREFIX)/sbin/chronyd
	chmod 555 $(INSTALL_PREFIX)/sbin/chronyd
	cp chronyc $(INSTALL_PREFIX)/bin/chronyc
	chown root $(INSTALL_PREFIX)/bin/chronyc
	chmod 555 $(INSTALL_PREFIX)/bin/chronyc
	cp chrony.txt $(INSTALL_PREFIX)/share/doc/chrony/chrony.txt
	chown root $(INSTALL_PREFIX)/share/doc/chrony/chrony.txt
	chmod 444 $(INSTALL_PREFIX)/share/doc/chrony/chrony.txt
	cp LICENCE $(INSTALL_PREFIX)/share/doc/chrony/LICENCE
	chown root $(INSTALL_PREFIX)/share/doc/chrony/LICENCE
	chmod 444 $(INSTALL_PREFIX)/share/doc/chrony/LICENCE
	cp README $(INSTALL_PREFIX)/share/doc/chrony/README
	chown root $(INSTALL_PREFIX)/share/doc/chrony/README
	chmod 444 $(INSTALL_PREFIX)/share/doc/chrony/README

%.o : %.c
	$(CC) $(CFLAGS) $(DEFS) -c $<

%.s : %.c
	$(CC) $(CFLAGS) $(DEFS) -S $<

main.o logging.o client.o : version.h