1# Automake input for strace. 2 3SUBDIRS = tests 4 5bin_PROGRAMS = strace 6man_MANS = strace.1 7bin_SCRIPTS = strace-graph strace-log-merge 8 9OS = linux 10# ARCH is `i386', `m68k', `sparc', etc. 11ARCH = @arch@ 12 13ACLOCAL_AMFLAGS = -I m4 14AM_CFLAGS = $(WARN_CFLAGS) 15AM_CPPFLAGS = -I$(srcdir)/$(OS)/$(ARCH) -I$(srcdir)/$(OS) -I$(builddir)/$(OS) 16 17include xlat/Makemodule.am 18 19strace_SOURCES = \ 20 aio.c \ 21 bjm.c \ 22 block.c \ 23 count.c \ 24 desc.c \ 25 fanotify.c \ 26 file.c \ 27 inotify.c \ 28 io.c \ 29 ioctl.c \ 30 ioprio.c \ 31 ipc.c \ 32 kexec.c \ 33 keyctl.c \ 34 ldt.c \ 35 loop.c \ 36 mem.c \ 37 mtd.c \ 38 net.c \ 39 pathtrace.c \ 40 process.c \ 41 ptp.c \ 42 quota.c \ 43 reboot.c \ 44 resource.c \ 45 scsi.c \ 46 signal.c \ 47 sock.c \ 48 strace.c \ 49 stream.c \ 50 syscall.c \ 51 system.c \ 52 term.c \ 53 time.c \ 54 util.c \ 55 vsprintf.c 56 57if USE_LIBUNWIND 58strace_SOURCES += unwind.c 59strace_CPPFLAGS = $(AM_CPPFLAGS) $(libunwind_CPPFLAGS) 60strace_LDFLAGS = $(libunwind_LDFLAGS) 61strace_LDADD = $(libunwind_LIBS) 62else 63strace_CPPFLAGS = $(AM_CPPFLAGS) 64endif 65 66noinst_HEADERS = defs.h 67# Enable this to get link map generated 68#strace_CFLAGS = $(AM_CFLAGS) -Wl,-Map=strace.mapfile 69 70EXTRA_DIST = \ 71 $(man_MANS) \ 72 .version \ 73 COPYING \ 74 CREDITS \ 75 ChangeLog \ 76 ChangeLog-CVS \ 77 README-linux \ 78 README-linux-ptrace \ 79 debian/changelog \ 80 debian/compat \ 81 debian/control \ 82 debian/copyright \ 83 debian/rules \ 84 debian/source/format \ 85 debian/strace-udeb.install \ 86 debian/strace.docs \ 87 debian/strace.examples \ 88 debian/strace.install \ 89 debian/strace.manpages \ 90 debian/strace64.install \ 91 debian/strace64.manpages \ 92 debian/watch \ 93 errnoent.sh \ 94 linux/aarch64/errnoent1.h \ 95 linux/aarch64/ioctlent.h.in \ 96 linux/aarch64/ioctlent1.h \ 97 linux/aarch64/signalent1.h \ 98 linux/aarch64/syscallent.h \ 99 linux/aarch64/syscallent1.h \ 100 linux/alpha/errnoent.h \ 101 linux/alpha/ioctlent.h.in \ 102 linux/alpha/signalent.h \ 103 linux/alpha/syscallent.h \ 104 linux/arc/ioctlent.h.in \ 105 linux/arc/syscallent.h \ 106 linux/arm/ioctlent.h.in \ 107 linux/arm/syscallent.h \ 108 linux/avr32/ioctlent.h.in \ 109 linux/avr32/syscallent.h \ 110 linux/bfin/ioctlent.h.in \ 111 linux/bfin/syscallent.h \ 112 linux/dummy.h \ 113 linux/errnoent.h \ 114 linux/fanotify.h \ 115 linux/hppa/errnoent.h \ 116 linux/hppa/ioctlent.h.in \ 117 linux/hppa/signalent.h \ 118 linux/hppa/syscallent.h \ 119 linux/i386/ioctlent.h.in \ 120 linux/i386/syscallent.h \ 121 linux/ia64/ioctlent.h.in \ 122 linux/ia64/signalent.h \ 123 linux/ia64/syscallent.h \ 124 linux/inotify.h \ 125 linux/ioctlent-filter.awk \ 126 linux/ioctlent.h.in \ 127 linux/ioctlent.sh \ 128 linux/ioctlsort.c \ 129 linux/kexec.h \ 130 linux/keyctl.h \ 131 linux/m68k/ioctlent.h.in \ 132 linux/m68k/syscallent.h \ 133 linux/metag/ioctlent.h.in \ 134 linux/metag/syscallent.h \ 135 linux/microblaze/ioctlent.h.in \ 136 linux/microblaze/syscallent.h \ 137 linux/mips/errnoent.h \ 138 linux/mips/ioctlent.h.in \ 139 linux/mips/ioctlent.sh \ 140 linux/mips/signalent.h \ 141 linux/mips/syscallent-compat.h \ 142 linux/mips/syscallent-n32.h \ 143 linux/mips/syscallent-n64.h \ 144 linux/mips/syscallent-o32.h \ 145 linux/mips/syscallent.h \ 146 linux/mtd-abi.h \ 147 linux/or1k/ioctlent.h.in \ 148 linux/or1k/syscallent.h \ 149 linux/personality.h \ 150 linux/powerpc/errnoent1.h \ 151 linux/powerpc/ioctlent.h.in \ 152 linux/powerpc/ioctlent1.h \ 153 linux/powerpc/signalent1.h \ 154 linux/powerpc/syscallent.h \ 155 linux/powerpc/syscallent1.h \ 156 linux/ptp_clock.h \ 157 linux/reboot.h \ 158 linux/s390/ioctlent.h.in \ 159 linux/s390/syscallent.h \ 160 linux/s390x/ioctlent.h.in \ 161 linux/s390x/syscallent.h \ 162 linux/sh/ioctlent.h.in \ 163 linux/sh/syscallent.h \ 164 linux/sh64/ioctlent.h.in \ 165 linux/sh64/syscallent.h \ 166 linux/signalent.h \ 167 linux/sparc/dummy2.h \ 168 linux/sparc/errnoent.h \ 169 linux/sparc/errnoent1.h \ 170 linux/sparc/gen.pl \ 171 linux/sparc/ioctlent.h.in \ 172 linux/sparc/ioctlent1.h \ 173 linux/sparc/signalent.h \ 174 linux/sparc/signalent1.h \ 175 linux/sparc/syscall1.h \ 176 linux/sparc/syscallent.h \ 177 linux/sparc/syscallent1.h \ 178 linux/sparc64/dummy2.h \ 179 linux/sparc64/errnoent.h \ 180 linux/sparc64/errnoent1.h \ 181 linux/sparc64/errnoent2.h \ 182 linux/sparc64/ioctlent.h.in \ 183 linux/sparc64/ioctlent1.h \ 184 linux/sparc64/ioctlent2.h \ 185 linux/sparc64/signalent.h \ 186 linux/sparc64/signalent1.h \ 187 linux/sparc64/signalent2.h \ 188 linux/sparc64/syscall1.h \ 189 linux/sparc64/syscallent.h \ 190 linux/sparc64/syscallent1.h \ 191 linux/sparc64/syscallent2.h \ 192 linux/subcall.h \ 193 linux/syscall.h \ 194 linux/tile/errnoent1.h \ 195 linux/tile/ioctlent.h.in \ 196 linux/tile/ioctlent1.h \ 197 linux/tile/signalent1.h \ 198 linux/tile/syscallent.h \ 199 linux/tile/syscallent1.h \ 200 linux/ubi-user.h \ 201 linux/x32/errnoent.h \ 202 linux/x32/errnoent1.h \ 203 linux/x32/ioctlent.h.in \ 204 linux/x32/ioctlent1.h \ 205 linux/x32/signalent.h \ 206 linux/x32/signalent1.h \ 207 linux/x32/syscallent.h \ 208 linux/x32/syscallent1.h \ 209 linux/x86_64/errnoent1.h \ 210 linux/x86_64/errnoent2.h \ 211 linux/x86_64/gentab.pl \ 212 linux/x86_64/ioctlent.h.in \ 213 linux/x86_64/ioctlent1.h \ 214 linux/x86_64/ioctlent2.h \ 215 linux/x86_64/signalent1.h \ 216 linux/x86_64/signalent2.h \ 217 linux/x86_64/syscallent.h \ 218 linux/x86_64/syscallent1.h \ 219 linux/x86_64/syscallent2.h \ 220 linux/xtensa/ioctlent.h.in \ 221 linux/xtensa/syscallent.h \ 222 signalent.sh \ 223 strace-graph \ 224 strace-log-merge \ 225 strace.spec \ 226 syscallent.sh \ 227 $(XLAT_INPUT_FILES) \ 228 $(XLAT_HEADER_FILES) \ 229 xlat/gen.sh \ 230 xlate.el 231 232.PHONY: srpm 233srpm: dist-xz 234 rpmbuild --define '%_srcrpmdir .' -ts $(distdir).tar.xz 235 236BUILT_SOURCES = .version 237 238$(srcdir)/.version: 239 $(AM_V_GEN)echo $(VERSION) > $@-t && mv $@-t $@ 240 241dist-hook: 242 $(AM_V_GEN)echo $(VERSION) > $(distdir)/.tarball-version 243 244today = $(shell date +%Y-%m-%d) 245version_regexp = $(subst .,\.,$(VERSION)) 246news_check_regexp = 'Noteworthy changes in release $(version_regexp) ($(today))' 247 248news-check: NEWS 249 $(AM_V_GEN)if head -1 $< | \ 250 grep -x $(news_check_regexp) >/dev/null; then \ 251 :; \ 252 else \ 253 echo >&2 '$<: check failed'; \ 254 exit 1; \ 255 fi 256 257if MAINTAINER_MODE 258 259gen_changelog_start_date = 2009-07-08 20:00 260$(srcdir)/ChangeLog: $(srcdir)/gitlog-to-changelog $(srcdir)/Makefile.in \ 261 $(srcdir)/.version 262 @rm -f $@.new 263 (cd $(srcdir); \ 264 ./gitlog-to-changelog --append-dot \ 265 --since='$(gen_changelog_start_date)'; \ 266 echo; echo; echo 'See ChangeLog-CVS for older changes.' \ 267 ) > $@.new 268 chmod 444 $@.new 269 mv -f $@.new $@ 270 271$(srcdir)/CREDITS: $(srcdir)/CREDITS.in $(srcdir)/.mailmap \ 272 $(srcdir)/Makefile.in $(srcdir)/.version 273 $(AM_V_GEN) \ 274 { \ 275 cd $(srcdir); \ 276 sed '/^##/,$$d' CREDITS.in; \ 277 { sed -n '1,/^##>/d; s/ \+/\t/; s/^./&/p' CREDITS.in; \ 278 git log --pretty=format:'%aN %aE'; \ 279 } | LC_ALL=C sort -u \ 280 | awk -F'\t' '{printf("\t%s <%s>\n",$$1,$$2)}'; \ 281 } > $@-t && mv $@-t $@ 282 283export TAR_OPTIONS = --owner=0 --group=0 --numeric-owner --mode=go-w,go+rX 284 285IOCTLDIR = /usr/include 286IOCTLASM = asm 287IOCTLSORT_INCLUDEDIR = $(IOCTLDIR) 288 289ioctlent_h_in = linux/ioctlent.h.in 290 291BUILT_SOURCES += $(ioctlent_h_in) 292 293$(srcdir)/$(ioctlent_h_in): ioctlsort 294 $(<D)/$(<F) > $@ 295ioctlsort: $(srcdir)/linux/ioctlsort.c ioctls.h ioctldefs.h 296 $(filter-out -I%,$(LINK.c)) -I. -I$(IOCTLSORT_INCLUDEDIR) \ 297 $(filter -I%,$(LINK.c)) \ 298 -o $@ $< 299ioctls.h: $(srcdir)/linux/ioctlent.sh 300 $(SHELL) $< $(IOCTLDIR) $(IOCTLASM) 301ioctldefs.h: ioctls.h ; 302 303endif 304 305ioctlent_h = $(builddir)/$(OS)/ioctlent.h 306BUILT_SOURCES += $(ioctlent_h) 307CLEANFILES = $(ioctlent_h) 308ioctlent_h_deps = $(srcdir)/$(OS)/ioctlent.h.in $(srcdir)/$(OS)/$(ARCH)/ioctlent.h.in 309$(ioctlent_h): $(top_builddir)/config.status $(ioctlent_h_deps) 310 $(MKDIR_P) $(builddir)/$(OS) 311 cat $(ioctlent_h_deps) | \ 312 $(COMPILE) -E -P - | \ 313 LC_ALL=C sort -u -k3,3 -k2,2 | \ 314 awk -f $(srcdir)/linux/ioctlent-filter.awk > $@ 315