Makefile.am revision 107207
1# $Id: Makefile.am,v 1.122.4.1 2002/10/21 15:03:04 joda Exp $ 2 3include $(top_srcdir)/Makefile.am.common 4 5ACLOCAL_AMFLAGS = -I ../../cf 6 7CLEANFILES = roken.h make-roken.c $(XHEADERS) 8 9lib_LTLIBRARIES = libroken.la 10libroken_la_LDFLAGS = -version-info 16:1:0 11 12noinst_PROGRAMS = make-roken snprintf-test 13 14nodist_make_roken_SOURCES = make-roken.c 15 16check_PROGRAMS = \ 17 base64-test \ 18 getaddrinfo-test \ 19 parse_bytes-test \ 20 parse_reply-test \ 21 snprintf-test \ 22 strpftime-test 23 24TESTS = $(check_PROGRAMS) 25 26LDADD = libroken.la $(LIB_crypt) 27make_roken_LDADD = 28 29noinst_LTLIBRARIES = libtest.la 30libtest_la_SOURCES = strftime.c strptime.c snprintf.c 31libtest_la_CFLAGS = -DTEST_SNPRINTF 32 33parse_reply_test_SOURCES = parse_reply-test.c resolve.c 34parse_reply_test_CFLAGS = -DTEST_RESOLVE 35 36strpftime_test_SOURCES = strpftime-test.c 37strpftime_test_LDADD = libtest.la $(LDADD) 38snprintf_test_SOURCES = snprintf-test.c 39snprintf_test_LDADD = libtest.la $(LDADD) 40snprintf_test_CFLAGS = -DTEST_SNPRINTF 41 42libroken_la_SOURCES = \ 43 base64.c \ 44 bswap.c \ 45 concat.c \ 46 environment.c \ 47 eread.c \ 48 esetenv.c \ 49 ewrite.c \ 50 getaddrinfo_hostspec.c \ 51 get_default_username.c \ 52 get_window_size.c \ 53 getarg.c \ 54 getnameinfo_verified.c \ 55 getprogname.c \ 56 h_errno.c \ 57 hostent_find_fqdn.c \ 58 issuid.c \ 59 k_getpwnam.c \ 60 k_getpwuid.c \ 61 mini_inetd.c \ 62 net_read.c \ 63 net_write.c \ 64 parse_bytes.c \ 65 parse_time.c \ 66 parse_units.c \ 67 resolve.c \ 68 roken_gethostby.c \ 69 rtbl.c \ 70 rtbl.h \ 71 setprogname.c \ 72 signal.c \ 73 simple_exec.c \ 74 snprintf.c \ 75 socket.c \ 76 strcollect.c \ 77 timeval.c \ 78 tm2time.c \ 79 unvis.c \ 80 verify.c \ 81 vis.c \ 82 vis.h \ 83 warnerr.c \ 84 write_pid.c \ 85 xdbm.h 86 87EXTRA_libroken_la_SOURCES = \ 88 chown.c \ 89 copyhostent.c \ 90 daemon.c \ 91 ecalloc.c \ 92 emalloc.c \ 93 erealloc.c \ 94 estrdup.c \ 95 err.c \ 96 err.hin \ 97 errx.c \ 98 fchown.c \ 99 flock.c \ 100 fnmatch.c \ 101 fnmatch.hin \ 102 freehostent.c \ 103 gai_strerror.c \ 104 getdtablesize.c \ 105 getegid.c \ 106 geteuid.c \ 107 getgid.c \ 108 gethostname.c \ 109 getifaddrs.c \ 110 getipnodebyaddr.c \ 111 getipnodebyname.c \ 112 getopt.c \ 113 gettimeofday.c \ 114 getuid.c \ 115 getusershell.c \ 116 glob.hin \ 117 hstrerror.c \ 118 ifaddrs.hin \ 119 inet_aton.c \ 120 inet_ntop.c \ 121 inet_pton.c \ 122 initgroups.c \ 123 innetgr.c \ 124 iruserok.c \ 125 lstat.c \ 126 memmove.c \ 127 mkstemp.c \ 128 putenv.c \ 129 rcmd.c \ 130 readv.c \ 131 recvmsg.c \ 132 sendmsg.c \ 133 setegid.c \ 134 setenv.c \ 135 seteuid.c \ 136 strcasecmp.c \ 137 strdup.c \ 138 strerror.c \ 139 strftime.c \ 140 strlcat.c \ 141 strlcpy.c \ 142 strlwr.c \ 143 strncasecmp.c \ 144 strndup.c \ 145 strnlen.c \ 146 strptime.c \ 147 strsep.c \ 148 strsep_copy.c \ 149 strtok_r.c \ 150 strupr.c \ 151 swab.c \ 152 unsetenv.c \ 153 verr.c \ 154 verrx.c \ 155 vis.hin \ 156 vsyslog.c \ 157 vwarn.c \ 158 vwarnx.c \ 159 warn.c \ 160 warnx.c \ 161 writev.c 162 163EXTRA_DIST = roken.awk roken.h.in 164 165libroken_la_LIBADD = @LTLIBOBJS@ $(DBLIB) 166 167$(LTLIBOBJS) $(libroken_la_OBJECTS): $(include_HEADERS) roken.h $(XHEADERS) 168 169BUILT_SOURCES = make-roken.c roken.h 170 171if have_err_h 172err_h = 173else 174err_h = err.h 175endif 176 177if have_fnmatch_h 178fnmatch_h = 179else 180fnmatch_h = fnmatch.h 181endif 182 183if have_glob_h 184glob_h = 185else 186glob_h = glob.h 187endif 188 189if have_ifaddrs_h 190ifaddrs_h = 191else 192ifaddrs_h = ifaddrs.h 193endif 194 195if have_vis_h 196vis_h = 197else 198vis_h = vis.h 199endif 200 201## these are controlled by configure 202XHEADERS = $(err_h) $(fnmatch_h) $(glob_h) $(ifaddrs_h) $(vis_h) 203 204include_HEADERS = \ 205 base64.h \ 206 getarg.h \ 207 parse_bytes.h \ 208 parse_time.h \ 209 parse_units.h \ 210 resolve.h \ 211 roken-common.h \ 212 rtbl.h \ 213 xdbm.h \ 214 $(XHEADERS) 215 216nodist_include_HEADERS = roken.h 217 218man_MANS = getarg.3 219 220SUFFIXES += .hin 221.hin.h: 222 cp $< $@ 223 224roken.h: make-roken$(EXEEXT) 225 @./make-roken$(EXEEXT) > tmp.h ;\ 226 if [ -f roken.h ] && cmp -s tmp.h roken.h ; then rm -f tmp.h ; \ 227 else rm -f roken.h; mv tmp.h roken.h; fi 228 229make-roken.c: roken.h.in roken.awk 230 $(AWK) -f $(srcdir)/roken.awk $(srcdir)/roken.h.in > make-roken.c 231