]> granicus.if.org Git - strace/blob - Makefile.am
ef7e8ed8a8818aebc6f0c2beb62520e2108a5fef
[strace] / Makefile.am
1 # Automake input for strace.
2 #
3 # Copyright (c) 2002-2009 Roland McGrath <roland@redhat.com>
4 # Copyright (c) 2006-2016 Dmitry V. Levin <ldv@altlinux.org>
5 # Copyright (c) 2008-2015 Mike Frysinger <vapier@gentoo.org>
6 # Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
7 # Copyright (c) 2002-2017 The strace developers.
8 # All rights reserved.
9 #
10 # Redistribution and use in source and binary forms, with or without
11 # modification, are permitted provided that the following conditions
12 # are met:
13 # 1. Redistributions of source code must retain the above copyright
14 #    notice, this list of conditions and the following disclaimer.
15 # 2. Redistributions in binary form must reproduce the above copyright
16 #    notice, this list of conditions and the following disclaimer in the
17 #    documentation and/or other materials provided with the distribution.
18 # 3. The name of the author may not be used to endorse or promote products
19 #    derived from this software without specific prior written permission.
20 #
21 # THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
22 # IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
23 # OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
24 # IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
25 # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
26 # NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27 # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
30 # THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31
32 if HAVE_M32_RUNTIME
33 TESTS_M32 = tests-m32
34 endif
35 if HAVE_MX32_RUNTIME
36 TESTS_MX32 = tests-mx32
37 endif
38 SUBDIRS = . tests $(TESTS_M32) $(TESTS_MX32)
39
40 bin_PROGRAMS = strace
41 man_MANS = strace.1 strace-log-merge.1
42 bin_SCRIPTS = strace-graph strace-log-merge
43
44 OS              = linux
45 # ARCH is `i386', `m68k', `sparc', etc.
46 ARCH            = @arch@
47
48 READELF         = @READELF@
49
50 ACLOCAL_AMFLAGS = -I m4
51 AM_CFLAGS = $(WARN_CFLAGS)
52 AM_CPPFLAGS = -I$(builddir)/$(OS)/$(ARCH) \
53               -I$(srcdir)/$(OS)/$(ARCH) \
54               -I$(builddir)/$(OS) \
55               -I$(srcdir)/$(OS) \
56               -I$(builddir) \
57               -I$(srcdir)
58
59 AM_CFLAGS_FOR_BUILD = $(WARN_CFLAGS_FOR_BUILD)
60 AM_CPPFLAGS_FOR_BUILD = $(AM_CPPFLAGS)
61
62 include xlat/Makemodule.am
63
64 strace_CPPFLAGS = $(AM_CPPFLAGS)
65 strace_CFLAGS = $(AM_CFLAGS)
66 strace_LDFLAGS =
67 strace_LDADD = libstrace.a
68 noinst_LIBRARIES = libstrace.a
69
70 libstrace_a_CPPFLAGS = $(strace_CPPFLAGS)
71 libstrace_a_CFLAGS = $(strace_CFLAGS)
72 libstrace_a_SOURCES =   \
73         fstatfs.c \
74         fstatfs64.c \
75         ipc.c \
76         sigreturn.c     \
77         socketcall.c \
78         statfs.c \
79         statfs64.c \
80         sync_file_range.c \
81         sync_file_range2.c \
82         upeek.c         \
83         upoke.c         \
84         # end of libstrace_a_SOURCES
85
86 strace_SOURCES =        \
87         access.c        \
88         affinity.c      \
89         aio.c           \
90         alpha.c         \
91         arch_defs.h     \
92         basic_filters.c \
93         bind.c          \
94         bjm.c           \
95         block.c         \
96         bpf.c           \
97         bpf_filter.c    \
98         bpf_filter.h    \
99         bpf_fprog.h     \
100         bpf_seccomp_filter.c \
101         bpf_sock_filter.c \
102         btrfs.c         \
103         cacheflush.c    \
104         capability.c    \
105         caps0.h         \
106         caps1.h         \
107         chdir.c         \
108         chmod.c         \
109         clone.c         \
110         copy_file_range.c \
111         count.c         \
112         defs.h          \
113         desc.c          \
114         dirent.c        \
115         dirent64.c      \
116         dm.c            \
117         dyxlat.c        \
118         empty.h         \
119         epoll.c         \
120         error_prints.c  \
121         error_prints.h  \
122         evdev.c         \
123         eventfd.c       \
124         execve.c        \
125         fadvise.c       \
126         fallocate.c     \
127         fanotify.c      \
128         fchownat.c      \
129         fcntl.c         \
130         fetch_bpf_fprog.c \
131         fetch_struct_flock.c \
132         fetch_struct_keyctl_kdf_params.c \
133         fetch_struct_mmsghdr.c \
134         fetch_struct_msghdr.c \
135         fetch_struct_stat.c \
136         fetch_struct_stat64.c \
137         fetch_struct_statfs.c \
138         file_handle.c   \
139         file_ioctl.c    \
140         filter_qualify.c \
141         filter.h        \
142         flock.c         \
143         flock.h         \
144         fs_x_ioctl.c    \
145         futex.c         \
146         gcc_compat.h    \
147         get_robust_list.c \
148         getcpu.c        \
149         getcwd.c        \
150         getrandom.c     \
151         hdio.c          \
152         hostname.c      \
153         inotify.c       \
154         io.c            \
155         ioctl.c         \
156         ioperm.c        \
157         iopl.c          \
158         ioprio.c        \
159         ipc_defs.h      \
160         ipc_msg.c       \
161         ipc_msgctl.c    \
162         ipc_sem.c       \
163         ipc_shm.c       \
164         ipc_shmctl.c    \
165         kcmp.c          \
166         kernel_types.h  \
167         kexec.c         \
168         keyctl.c        \
169         keyctl_kdf_params.h \
170         kvm.c \
171         ldt.c           \
172         link.c          \
173         linux/asm_stat.h \
174         linux/x32/asm_stat.h \
175         linux/x86_64/asm_stat.h \
176         listen.c        \
177         lookup_dcookie.c \
178         loop.c          \
179         lseek.c         \
180         macros.h        \
181         mem.c           \
182         membarrier.c    \
183         memfd_create.c  \
184         mknod.c         \
185         mmsghdr.c       \
186         mount.c         \
187         mpers_type.h    \
188         mq.c            \
189         msghdr.c        \
190         msghdr.h        \
191         mtd.c           \
192         native_defs.h   \
193         negated_errno.h \
194         net.c           \
195         netlink.c       \
196         netlink.h       \
197         netlink_crypto.c \
198         netlink_sock_diag.h \
199         netlink_inet_diag.c \
200         netlink_netlink_diag.c \
201         netlink_packet_diag.c \
202         netlink_route.c \
203         netlink_route.h \
204         netlink_selinux.c \
205         netlink_smc_diag.c \
206         netlink_sock_diag.c \
207         netlink_unix_diag.c \
208         nlattr.c        \
209         nlattr.h        \
210         nsfs.c          \
211         nsfs.h          \
212         nsig.h          \
213         numa.c          \
214         number_set.c    \
215         number_set.h    \
216         oldstat.c       \
217         open.c          \
218         or1k_atomic.c   \
219         pathtrace.c     \
220         perf.c          \
221         perf_event_struct.h \
222         personality.c   \
223         pkeys.c         \
224         poll.c          \
225         prctl.c         \
226         print_dev_t.c   \
227         print_group_req.c \
228         print_fields.h  \
229         print_ifindex.c \
230         print_mq_attr.c \
231         print_msgbuf.c  \
232         print_sg_req_info.c \
233         print_sigevent.c \
234         print_statfs.c  \
235         print_struct_stat.c \
236         print_time.c    \
237         print_timespec.c \
238         print_timeval.c \
239         print_timex.c   \
240         printmode.c     \
241         printrusage.c   \
242         printsiginfo.c  \
243         printsiginfo.h  \
244         process.c       \
245         process_vm.c    \
246         ptp.c           \
247         ptrace.h        \
248         quota.c         \
249         readahead.c     \
250         readlink.c      \
251         reboot.c        \
252         regs.h          \
253         renameat.c      \
254         resource.c      \
255         rt_sigframe.c   \
256         rt_sigreturn.c  \
257         rtc.c           \
258         rtnl_addr.c     \
259         rtnl_addrlabel.c \
260         rtnl_dcb.c      \
261         rtnl_link.c     \
262         rtnl_mdb.c      \
263         rtnl_neigh.c    \
264         rtnl_neightbl.c \
265         rtnl_netconf.c  \
266         rtnl_nsid.c     \
267         rtnl_route.c    \
268         rtnl_rule.c     \
269         rtnl_tc.c       \
270         rtnl_tc_action.c \
271         sched.c         \
272         sched_attr.h    \
273         scsi.c          \
274         seccomp.c       \
275         sendfile.c      \
276         sg_io_v3.c      \
277         sg_io_v4.c      \
278         shutdown.c      \
279         sigaltstack.c   \
280         sigevent.h      \
281         signal.c        \
282         signalfd.c      \
283         sock.c          \
284         sockaddr.c      \
285         socketutils.c   \
286         sram_alloc.c    \
287         stat.c          \
288         stat.h          \
289         stat64.c        \
290         statfs.c        \
291         statfs.h        \
292         statx.c         \
293         statx.h         \
294         strace.c        \
295         string_to_uint.h \
296         string_to_uint.c \
297         supported_personalities.h \
298         swapon.c        \
299         syscall.c       \
300         sysctl.c        \
301         sysent.h        \
302         sysent_shorthand_defs.h \
303         sysent_shorthand_undefs.h \
304         sysinfo.c       \
305         syslog.c        \
306         sysmips.c       \
307         term.c          \
308         time.c          \
309         times.c         \
310         trace_event.h   \
311         truncate.c      \
312         ubi.c           \
313         ucopy.c         \
314         uid.c           \
315         uid16.c         \
316         umask.c         \
317         umount.c        \
318         uname.c         \
319         userfaultfd.c   \
320         ustat.c         \
321         util.c          \
322         utime.c         \
323         utimes.c        \
324         v4l2.c          \
325         wait.c          \
326         xattr.c         \
327         xlat.c          \
328         xlat.h          \
329         xmalloc.c       \
330         xmalloc.h       \
331         xstring.h       \
332         # end of strace_SOURCES
333
334 if USE_LIBUNWIND
335 strace_SOURCES += unwind.c
336 strace_CPPFLAGS += $(libunwind_CPPFLAGS)
337 strace_LDFLAGS += $(libunwind_LDFLAGS)
338 strace_LDADD += $(libunwind_LIBS)
339 if USE_DEMANGLE
340 strace_CPPFLAGS += $(libiberty_CPPFLAGS)
341 strace_LDFLAGS += $(libiberty_LDFLAGS)
342 strace_LDADD += $(libiberty_LIBS)
343 endif
344 endif
345
346 @CODE_COVERAGE_RULES@
347 CODE_COVERAGE_BRANCH_COVERAGE = 1
348 CODE_COVERAGE_GENHTML_OPTIONS = $(CODE_COVERAGE_GENHTML_OPTIONS_DEFAULT) \
349         --prefix $(shell cd $(abs_top_srcdir)/.. && pwd || echo .)
350 CODE_COVERAGE_IGNORE_PATTERN = '/usr/include/*'
351 strace_CPPFLAGS += $(CODE_COVERAGE_CPPFLAGS)
352 strace_CFLAGS += $(CODE_COVERAGE_CFLAGS)
353 strace_LDADD += $(CODE_COVERAGE_LIBS)
354
355 # Enable this to get link map generated
356 #strace_LDFLAGS += -Wl,-Map=strace.mapfile
357
358 EXTRA_DIST =                            \
359         $(man_MANS)                     \
360         .version                        \
361         COPYING                         \
362         CREDITS                         \
363         ChangeLog                       \
364         ChangeLog-CVS                   \
365         README-linux-ptrace             \
366         debian/changelog                \
367         debian/compat                   \
368         debian/control                  \
369         debian/copyright                \
370         debian/rules                    \
371         debian/source/format            \
372         debian/strace-udeb.install      \
373         debian/strace.docs              \
374         debian/strace.examples          \
375         debian/strace.install           \
376         debian/strace.manpages          \
377         debian/strace64.install         \
378         debian/strace64.manpages        \
379         debian/watch                    \
380         generate_sen.sh                 \
381         ioctl_iocdef.c                  \
382         ioctlsort.c                     \
383         linux/32/ioctls_inc.h           \
384         linux/32/ioctls_inc_align16.h   \
385         linux/32/ioctls_inc_align32.h   \
386         linux/32/ioctls_inc_align64.h   \
387         linux/32/syscallent.h           \
388         linux/64/ioctls_inc.h           \
389         linux/64/syscallent.h           \
390         linux/aarch64/arch_defs_.h      \
391         linux/aarch64/arch_regs.c       \
392         linux/aarch64/arch_regs.h       \
393         linux/aarch64/arch_rt_sigframe.c\
394         linux/aarch64/arch_sigreturn.c  \
395         linux/aarch64/errnoent1.h       \
396         linux/aarch64/get_error.c       \
397         linux/aarch64/get_scno.c        \
398         linux/aarch64/get_syscall_args.c\
399         linux/aarch64/ioctls_arch0.h    \
400         linux/aarch64/ioctls_arch1.h    \
401         linux/aarch64/ioctls_inc0.h     \
402         linux/aarch64/ioctls_inc1.h     \
403         linux/aarch64/set_error.c       \
404         linux/aarch64/set_scno.c        \
405         linux/aarch64/signalent1.h      \
406         linux/aarch64/syscallent.h      \
407         linux/aarch64/syscallent1.h     \
408         linux/alpha/arch_defs_.h                \
409         linux/alpha/arch_getrval2.c     \
410         linux/alpha/arch_regs.c         \
411         linux/alpha/arch_regs.h         \
412         linux/alpha/arch_rt_sigframe.c  \
413         linux/alpha/arch_sigreturn.c    \
414         linux/alpha/errnoent.h          \
415         linux/alpha/get_error.c         \
416         linux/alpha/get_scno.c          \
417         linux/alpha/get_syscall_args.c  \
418         linux/alpha/get_syscall_result.c\
419         linux/alpha/ioctls_arch0.h      \
420         linux/alpha/ioctls_inc0.h       \
421         linux/alpha/set_error.c         \
422         linux/alpha/set_scno.c          \
423         linux/alpha/signalent.h         \
424         linux/alpha/syscallent.h        \
425         linux/alpha/userent.h           \
426         linux/arc/arch_regs.c           \
427         linux/arc/arch_regs.h           \
428         linux/arc/arch_rt_sigframe.c    \
429         linux/arc/get_error.c           \
430         linux/arc/get_scno.c            \
431         linux/arc/get_syscall_args.c    \
432         linux/arc/ioctls_arch0.h        \
433         linux/arc/ioctls_inc0.h         \
434         linux/arc/set_error.c           \
435         linux/arc/set_scno.c            \
436         linux/arc/syscallent.h          \
437         linux/arch_defs_.h              \
438         linux/arch_kvm.c                \
439         linux/arch_regs.h               \
440         linux/arch_sigreturn.c          \
441         linux/arm/arch_defs_.h          \
442         linux/arm/arch_regs.c           \
443         linux/arm/arch_regs.h           \
444         linux/arm/arch_rt_sigframe.c    \
445         linux/arm/arch_sigreturn.c      \
446         linux/arm/get_error.c           \
447         linux/arm/get_scno.c            \
448         linux/arm/get_syscall_args.c    \
449         linux/arm/ioctls_arch0.h        \
450         linux/arm/ioctls_inc0.h         \
451         linux/arm/set_error.c           \
452         linux/arm/set_scno.c            \
453         linux/arm/syscallent.h          \
454         linux/arm/userent.h             \
455         linux/avr32/arch_regs.c         \
456         linux/avr32/arch_regs.h         \
457         linux/avr32/arch_rt_sigframe.c  \
458         linux/avr32/get_error.c         \
459         linux/avr32/get_scno.c          \
460         linux/avr32/get_syscall_args.c  \
461         linux/avr32/ioctls_arch0.h      \
462         linux/avr32/ioctls_inc0.h       \
463         linux/avr32/set_error.c         \
464         linux/avr32/set_scno.c          \
465         linux/avr32/syscallent.h        \
466         linux/avr32/userent.h           \
467         linux/bfin/arch_regs.c          \
468         linux/bfin/arch_rt_sigframe.c   \
469         linux/bfin/get_error.c          \
470         linux/bfin/get_scno.c           \
471         linux/bfin/get_syscall_args.c   \
472         linux/bfin/get_syscall_result.c \
473         linux/bfin/ioctls_arch0.h       \
474         linux/bfin/ioctls_inc0.h        \
475         linux/bfin/rt_sigframe.h        \
476         linux/bfin/set_error.c          \
477         linux/bfin/set_scno.c           \
478         linux/bfin/syscallent.h         \
479         linux/bfin/userent.h            \
480         linux/crisv10/arch_regs.c       \
481         linux/crisv10/arch_rt_sigframe.c\
482         linux/crisv10/arch_sigreturn.c  \
483         linux/crisv10/get_error.c       \
484         linux/crisv10/get_scno.c        \
485         linux/crisv10/get_syscall_args.c        \
486         linux/crisv10/get_syscall_result.c      \
487         linux/crisv10/rt_sigframe.h     \
488         linux/crisv10/set_error.c       \
489         linux/crisv10/set_scno.c        \
490         linux/crisv10/syscallent.h      \
491         linux/crisv10/userent.h         \
492         linux/crisv32/arch_regs.c       \
493         linux/crisv32/arch_rt_sigframe.c\
494         linux/crisv32/arch_sigreturn.c  \
495         linux/crisv32/get_error.c       \
496         linux/crisv32/get_scno.c        \
497         linux/crisv32/get_syscall_args.c        \
498         linux/crisv32/get_syscall_result.c      \
499         linux/crisv32/rt_sigframe.h     \
500         linux/crisv32/set_error.c       \
501         linux/crisv32/set_scno.c        \
502         linux/crisv32/syscallent.h      \
503         linux/crisv32/userent.h         \
504         linux/dummy.h                   \
505         linux/errnoent.h                \
506         linux/getregs_old.h             \
507         linux/hppa/arch_regs.c          \
508         linux/hppa/arch_regs.h          \
509         linux/hppa/arch_rt_sigframe.c   \
510         linux/hppa/errnoent.h           \
511         linux/hppa/get_error.c          \
512         linux/hppa/get_scno.c           \
513         linux/hppa/get_syscall_args.c   \
514         linux/hppa/get_syscall_result.c \
515         linux/hppa/ioctls_arch0.h       \
516         linux/hppa/ioctls_inc0.h        \
517         linux/hppa/rt_sigframe.h        \
518         linux/hppa/set_error.c          \
519         linux/hppa/set_scno.c           \
520         linux/hppa/signalent.h          \
521         linux/hppa/syscallent.h         \
522         linux/i386/arch_kvm.c           \
523         linux/i386/arch_defs_.h         \
524         linux/i386/arch_regs.c          \
525         linux/i386/arch_regs.h          \
526         linux/i386/arch_rt_sigframe.c   \
527         linux/i386/arch_sigreturn.c     \
528         linux/i386/get_error.c          \
529         linux/i386/get_scno.c           \
530         linux/i386/get_syscall_args.c   \
531         linux/i386/ioctls_arch0.h       \
532         linux/i386/ioctls_inc0.h        \
533         linux/i386/rt_sigframe.h        \
534         linux/i386/set_error.c          \
535         linux/i386/set_scno.c           \
536         linux/i386/syscallent.h         \
537         linux/i386/userent.h            \
538         linux/i386/userent0.h           \
539         linux/ia64/arch_defs_.h         \
540         linux/ia64/arch_getrval2.c      \
541         linux/ia64/arch_regs.c          \
542         linux/ia64/arch_regs.h          \
543         linux/ia64/arch_rt_sigframe.c   \
544         linux/ia64/get_error.c          \
545         linux/ia64/get_scno.c           \
546         linux/ia64/get_syscall_args.c   \
547         linux/ia64/ioctls_arch0.h       \
548         linux/ia64/ioctls_inc0.h        \
549         linux/ia64/rt_sigframe.h        \
550         linux/ia64/set_error.c          \
551         linux/ia64/set_scno.c           \
552         linux/ia64/syscallent.h         \
553         linux/ia64/userent.h            \
554         linux/inet_diag.h               \
555         linux/m68k/arch_defs_.h         \
556         linux/m68k/arch_regs.c          \
557         linux/m68k/arch_regs.h          \
558         linux/m68k/arch_rt_sigframe.c   \
559         linux/m68k/arch_sigreturn.c     \
560         linux/m68k/get_error.c          \
561         linux/m68k/get_scno.c           \
562         linux/m68k/get_syscall_args.c   \
563         linux/m68k/ioctls_arch0.h       \
564         linux/m68k/ioctls_inc0.h        \
565         linux/m68k/rt_sigframe.h        \
566         linux/m68k/set_error.c          \
567         linux/m68k/set_scno.c           \
568         linux/m68k/syscallent.h         \
569         linux/m68k/userent.h            \
570         linux/metag/arch_regs.c         \
571         linux/metag/arch_regs.h         \
572         linux/metag/arch_rt_sigframe.c  \
573         linux/metag/get_error.c         \
574         linux/metag/get_scno.c          \
575         linux/metag/get_syscall_args.c  \
576         linux/metag/ioctls_arch0.h      \
577         linux/metag/ioctls_inc0.h       \
578         linux/metag/set_error.c         \
579         linux/metag/set_scno.c          \
580         linux/metag/syscallent.h        \
581         linux/microblaze/arch_regs.c    \
582         linux/microblaze/arch_rt_sigframe.c\
583         linux/microblaze/arch_sigreturn.c       \
584         linux/microblaze/get_error.c    \
585         linux/microblaze/get_scno.c     \
586         linux/microblaze/get_syscall_args.c     \
587         linux/microblaze/get_syscall_result.c   \
588         linux/microblaze/ioctls_arch0.h \
589         linux/microblaze/ioctls_inc0.h  \
590         linux/microblaze/set_error.c    \
591         linux/microblaze/set_scno.c     \
592         linux/microblaze/syscallent.h   \
593         linux/microblaze/userent.h      \
594         linux/mips/arch_defs_.h         \
595         linux/mips/arch_getrval2.c      \
596         linux/mips/arch_regs.c          \
597         linux/mips/arch_regs.h          \
598         linux/mips/arch_rt_sigframe.c   \
599         linux/mips/arch_sigreturn.c     \
600         linux/mips/errnoent.h           \
601         linux/mips/genstub.sh           \
602         linux/mips/get_error.c          \
603         linux/mips/get_scno.c           \
604         linux/mips/get_syscall_args.c   \
605         linux/mips/ioctls_arch0.h       \
606         linux/mips/ioctls_inc0.h        \
607         linux/mips/rt_sigframe.h        \
608         linux/mips/set_error.c          \
609         linux/mips/set_scno.c           \
610         linux/mips/signalent.h          \
611         linux/mips/syscallent-compat.h  \
612         linux/mips/syscallent-n32.h     \
613         linux/mips/syscallent-n64.h     \
614         linux/mips/syscallent-o32.h     \
615         linux/mips/syscallent.h         \
616         linux/mips/userent.h            \
617         linux/netlink_diag.h            \
618         linux/nios2/arch_regs.c         \
619         linux/nios2/arch_regs.h         \
620         linux/nios2/arch_rt_sigframe.c  \
621         linux/nios2/get_error.c         \
622         linux/nios2/get_scno.c          \
623         linux/nios2/get_syscall_args.c  \
624         linux/nios2/ioctls_arch0.h      \
625         linux/nios2/ioctls_inc0.h       \
626         linux/nios2/set_error.c         \
627         linux/nios2/set_scno.c          \
628         linux/nios2/syscallent.h        \
629         linux/or1k/arch_regs.c          \
630         linux/or1k/arch_regs.h          \
631         linux/or1k/arch_rt_sigframe.c   \
632         linux/or1k/get_error.c          \
633         linux/or1k/get_scno.c           \
634         linux/or1k/get_syscall_args.c   \
635         linux/or1k/ioctls_arch0.h       \
636         linux/or1k/ioctls_inc0.h        \
637         linux/or1k/set_error.c          \
638         linux/or1k/set_scno.c           \
639         linux/or1k/syscallent.h         \
640         linux/or1k/userent.h            \
641         linux/packet_diag.h             \
642         linux/powerpc/arch_regs.c       \
643         linux/powerpc/arch_regs.h       \
644         linux/powerpc/arch_rt_sigframe.c\
645         linux/powerpc/arch_sigreturn.c  \
646         linux/powerpc/errnoent.h        \
647         linux/powerpc/get_error.c       \
648         linux/powerpc/get_scno.c        \
649         linux/powerpc/get_syscall_args.c        \
650         linux/powerpc/getregs_old.c     \
651         linux/powerpc/getregs_old.h     \
652         linux/powerpc/ioctls_arch0.h    \
653         linux/powerpc/ioctls_inc0.h     \
654         linux/powerpc/set_error.c       \
655         linux/powerpc/set_scno.c        \
656         linux/powerpc/syscallent.h      \
657         linux/powerpc/userent.h         \
658         linux/powerpc64/arch_regs.c     \
659         linux/powerpc64/arch_regs.h     \
660         linux/powerpc64/arch_rt_sigframe.c\
661         linux/powerpc64/arch_sigreturn.c        \
662         linux/powerpc64/errnoent.h      \
663         linux/powerpc64/errnoent1.h     \
664         linux/powerpc64/get_error.c     \
665         linux/powerpc64/get_scno.c      \
666         linux/powerpc64/get_syscall_args.c      \
667         linux/powerpc64/getregs_old.c   \
668         linux/powerpc64/getregs_old.h   \
669         linux/powerpc64/ioctls_arch0.h  \
670         linux/powerpc64/ioctls_arch1.h  \
671         linux/powerpc64/ioctls_inc0.h   \
672         linux/powerpc64/ioctls_inc1.h   \
673         linux/powerpc64/rt_sigframe.h   \
674         linux/powerpc64/set_error.c     \
675         linux/powerpc64/set_scno.c      \
676         linux/powerpc64/signalent1.h    \
677         linux/powerpc64/syscallent.h    \
678         linux/powerpc64/syscallent1.h   \
679         linux/powerpc64/userent.h       \
680         linux/riscv/arch_regs.c         \
681         linux/riscv/arch_regs.h         \
682         linux/riscv/arch_rt_sigframe.c  \
683         linux/riscv/errnoent1.h         \
684         linux/riscv/get_error.c         \
685         linux/riscv/get_scno.c          \
686         linux/riscv/get_syscall_args.c  \
687         linux/riscv/ioctls_arch0.h      \
688         linux/riscv/ioctls_arch1.h      \
689         linux/riscv/ioctls_inc0.h       \
690         linux/riscv/ioctls_inc1.h       \
691         linux/riscv/set_error.c         \
692         linux/riscv/set_scno.c          \
693         linux/riscv/signalent1.h        \
694         linux/riscv/syscallent.h        \
695         linux/riscv/syscallent1.h       \
696         linux/rt_sigframe.h             \
697         linux/s390/arch_defs_.h         \
698         linux/s390/arch_regs.c          \
699         linux/s390/arch_regs.h          \
700         linux/s390/arch_rt_sigframe.c   \
701         linux/s390/arch_sigreturn.c     \
702         linux/s390/get_error.c          \
703         linux/s390/get_scno.c           \
704         linux/s390/get_syscall_args.c   \
705         linux/s390/ioctls_arch0.h       \
706         linux/s390/ioctls_inc0.h        \
707         linux/s390/rt_sigframe.h        \
708         linux/s390/set_error.c          \
709         linux/s390/set_scno.c           \
710         linux/s390/syscallent.h         \
711         linux/s390/userent.h            \
712         linux/s390/userent0.h           \
713         linux/s390/userent1.h           \
714         linux/s390x/arch_defs_.h                \
715         linux/s390x/arch_regs.c         \
716         linux/s390x/arch_regs.h         \
717         linux/s390x/arch_rt_sigframe.c  \
718         linux/s390x/arch_sigreturn.c    \
719         linux/s390x/errnoent1.h         \
720         linux/s390x/get_error.c         \
721         linux/s390x/get_scno.c          \
722         linux/s390x/get_syscall_args.c  \
723         linux/s390x/ioctls_arch0.h      \
724         linux/s390x/ioctls_arch1.h      \
725         linux/s390x/ioctls_inc0.h       \
726         linux/s390x/ioctls_inc1.h       \
727         linux/s390x/rt_sigframe.h       \
728         linux/s390x/set_error.c         \
729         linux/s390x/set_scno.c          \
730         linux/s390x/signalent1.h        \
731         linux/s390x/syscallent.h        \
732         linux/s390x/syscallent1.h       \
733         linux/s390x/userent.h           \
734         linux/sh/arch_defs_.h           \
735         linux/sh/arch_getrval2.c        \
736         linux/sh/arch_regs.c            \
737         linux/sh/arch_rt_sigframe.c     \
738         linux/sh/get_error.c            \
739         linux/sh/get_scno.c             \
740         linux/sh/get_syscall_args.c     \
741         linux/sh/get_syscall_result.c   \
742         linux/sh/ioctls_arch0.h         \
743         linux/sh/ioctls_inc0.h          \
744         linux/sh/set_error.c            \
745         linux/sh/set_scno.c             \
746         linux/sh/syscallent.h           \
747         linux/sh/userent.h              \
748         linux/sh/userent0.h             \
749         linux/sh64/arch_regs.c          \
750         linux/sh64/arch_regs.h          \
751         linux/sh64/arch_rt_sigframe.c   \
752         linux/sh64/get_error.c          \
753         linux/sh64/get_scno.c           \
754         linux/sh64/get_syscall_args.c   \
755         linux/sh64/get_syscall_result.c \
756         linux/sh64/ioctls_arch0.h       \
757         linux/sh64/ioctls_inc0.h        \
758         linux/sh64/rt_sigframe.h        \
759         linux/sh64/set_error.c          \
760         linux/sh64/set_scno.c           \
761         linux/sh64/syscallent.h         \
762         linux/sh64/userent.h            \
763         linux/signalent.h               \
764         linux/smc_diag.h                \
765         linux/sock_diag.h               \
766         linux/sparc/arch_defs_.h                \
767         linux/sparc/arch_getrval2.c     \
768         linux/sparc/arch_regs.c         \
769         linux/sparc/arch_regs.h         \
770         linux/sparc/arch_rt_sigframe.c  \
771         linux/sparc/arch_sigreturn.c    \
772         linux/sparc/errnoent.h          \
773         linux/sparc/gen.pl              \
774         linux/sparc/get_error.c         \
775         linux/sparc/get_scno.c          \
776         linux/sparc/get_syscall_args.c  \
777         linux/sparc/ioctls_arch0.h      \
778         linux/sparc/ioctls_inc0.h       \
779         linux/sparc/rt_sigframe.h       \
780         linux/sparc/set_error.c         \
781         linux/sparc/set_scno.c          \
782         linux/sparc/signalent.h         \
783         linux/sparc/syscallent.h        \
784         linux/sparc/userent.h           \
785         linux/sparc64/arch_defs_.h      \
786         linux/sparc64/arch_getrval2.c   \
787         linux/sparc64/arch_regs.c       \
788         linux/sparc64/arch_regs.h       \
789         linux/sparc64/arch_rt_sigframe.c\
790         linux/sparc64/arch_sigreturn.c  \
791         linux/sparc64/errnoent.h        \
792         linux/sparc64/errnoent1.h       \
793         linux/sparc64/get_error.c       \
794         linux/sparc64/get_scno.c        \
795         linux/sparc64/get_syscall_args.c\
796         linux/sparc64/ioctls_arch0.h    \
797         linux/sparc64/ioctls_arch1.h    \
798         linux/sparc64/ioctls_inc0.h     \
799         linux/sparc64/ioctls_inc1.h     \
800         linux/sparc64/rt_sigframe.h     \
801         linux/sparc64/set_error.c       \
802         linux/sparc64/set_scno.c        \
803         linux/sparc64/signalent.h       \
804         linux/sparc64/signalent1.h      \
805         linux/sparc64/syscallent.h      \
806         linux/sparc64/syscallent1.h     \
807         linux/sparc64/userent.h         \
808         linux/subcall.h                 \
809         linux/syscall.h                 \
810         linux/tile/arch_regs.c          \
811         linux/tile/arch_regs.h          \
812         linux/tile/arch_rt_sigframe.c   \
813         linux/tile/arch_sigreturn.c     \
814         linux/tile/errnoent1.h          \
815         linux/tile/get_error.c          \
816         linux/tile/get_scno.c           \
817         linux/tile/get_syscall_args.c   \
818         linux/tile/ioctls_arch0.h       \
819         linux/tile/ioctls_arch1.h       \
820         linux/tile/ioctls_inc0.h        \
821         linux/tile/ioctls_inc1.h        \
822         linux/tile/rt_sigframe.h        \
823         linux/tile/set_error.c          \
824         linux/tile/set_scno.c           \
825         linux/tile/signalent1.h         \
826         linux/tile/syscallent.h         \
827         linux/tile/syscallent1.h        \
828         linux/tile/userent.h            \
829         linux/unix_diag.h               \
830         linux/userent.h                 \
831         linux/userent0.h                \
832         linux/x32/arch_defs_.h          \
833         linux/x32/arch_kvm.c            \
834         linux/x32/arch_regs.c           \
835         linux/x32/arch_regs.h           \
836         linux/x32/arch_rt_sigframe.c    \
837         linux/x32/arch_sigreturn.c      \
838         linux/x32/errnoent1.h           \
839         linux/x32/get_error.c           \
840         linux/x32/get_scno.c            \
841         linux/x32/get_syscall_args.c    \
842         linux/x32/ioctls_arch0.h        \
843         linux/x32/ioctls_arch1.h        \
844         linux/x32/ioctls_inc0.h         \
845         linux/x32/ioctls_inc1.h         \
846         linux/x32/rt_sigframe.h         \
847         linux/x32/set_error.c           \
848         linux/x32/set_scno.c            \
849         linux/x32/signalent1.h          \
850         linux/x32/syscallent.h          \
851         linux/x32/syscallent1.h         \
852         linux/x32/userent.h             \
853         linux/x86_64/arch_defs_.h       \
854         linux/x86_64/arch_kvm.c         \
855         linux/x86_64/arch_regs.c        \
856         linux/x86_64/arch_regs.h        \
857         linux/x86_64/arch_rt_sigframe.c \
858         linux/x86_64/arch_sigreturn.c   \
859         linux/x86_64/errnoent1.h        \
860         linux/x86_64/errnoent2.h        \
861         linux/x86_64/gentab.pl          \
862         linux/x86_64/get_error.c        \
863         linux/x86_64/get_scno.c         \
864         linux/x86_64/get_syscall_args.c \
865         linux/x86_64/getregs_old.c      \
866         linux/x86_64/getregs_old.h      \
867         linux/x86_64/ioctls_arch0.h     \
868         linux/x86_64/ioctls_arch1.h     \
869         linux/x86_64/ioctls_arch2.h     \
870         linux/x86_64/ioctls_inc0.h      \
871         linux/x86_64/ioctls_inc1.h      \
872         linux/x86_64/ioctls_inc2.h      \
873         linux/x86_64/rt_sigframe.h      \
874         linux/x86_64/set_error.c        \
875         linux/x86_64/set_scno.c         \
876         linux/x86_64/signalent1.h       \
877         linux/x86_64/signalent2.h       \
878         linux/x86_64/syscallent.h       \
879         linux/x86_64/syscallent1.h      \
880         linux/x86_64/syscallent2.h      \
881         linux/x86_64/userent.h          \
882         linux/xtensa/arch_regs.c        \
883         linux/xtensa/arch_rt_sigframe.c \
884         linux/xtensa/get_error.c        \
885         linux/xtensa/get_scno.c         \
886         linux/xtensa/get_syscall_args.c \
887         linux/xtensa/get_syscall_result.c       \
888         linux/xtensa/ioctls_arch0.h     \
889         linux/xtensa/ioctls_inc0.h      \
890         linux/xtensa/set_error.c        \
891         linux/xtensa/set_scno.c         \
892         linux/xtensa/syscallent.h       \
893         linux/xtensa/userent.h          \
894         mpers.awk                       \
895         mpers.sh                        \
896         mpers_test.sh                   \
897         mpers_xlat.h                    \
898         scno.head                       \
899         strace-graph                    \
900         strace-log-merge                \
901         strace.spec                     \
902         $(XLAT_INPUT_FILES)             \
903         $(XLAT_HEADER_FILES)            \
904         xlat/gen.sh                     \
905         xlate.el
906
907 .PHONY: check-valgrind-local
908 check-valgrind-local:
909
910 .PHONY: srpm
911 srpm: dist-xz
912         rpmbuild --define '%_srcrpmdir .' -ts $(distdir).tar.xz
913
914 $(srcdir)/.version:
915         $(AM_V_GEN)echo $(VERSION) > $@-t && mv $@-t $@
916
917 strace_SOURCES_c = \
918         $(filter %.c,$(strace_SOURCES)) $(filter %.c,$(libstrace_a_SOURCES))
919
920 sys_func.h: $(patsubst %,$(srcdir)/%,$(strace_SOURCES_c))
921         for f in $^; do \
922                 sed -n 's/^SYS_FUNC(.*/extern &;/p' $$f; \
923         done | sort -u > $@
924
925 syscallent_names = subcall.h syscallent.h syscallent1.h \
926                    syscallent-n32.h syscallent-n64.h syscallent-o32.h
927 syscallent_patterns = $(patsubst %,\%/%,$(syscallent_names))
928 syscallent_files = $(filter $(syscallent_patterns),$(EXTRA_DIST))
929
930 sen.h: $(patsubst %,$(srcdir)/%,$(syscallent_files))
931         for f in $^; do cat -- $$f; done | \
932                 $(srcdir)/generate_sen.sh > $@
933
934 dist-hook:
935         $(AM_V_GEN)echo $(VERSION) > $(distdir)/.tarball-version
936         ${AM_V_GEN}echo $(COPYRIGHT_YEAR) > $(distdir)/.year
937         ${AM_V_GEN}echo $(MANPAGE_DATE) > $(distdir)/.strace.1.in.date
938
939 today = $(shell date +%Y-%m-%d)
940 version_regexp = $(subst .,\.,$(VERSION))
941 news_check_regexp = 'Noteworthy changes in release $(version_regexp) ($(today))'
942
943 news-check: NEWS
944         $(AM_V_GEN)if head -1 $< |                              \
945           grep -x $(news_check_regexp) >/dev/null; then         \
946                 :;                                              \
947         else                                                    \
948                 echo >&2 '$<: check failed';                    \
949                 exit 1;                                         \
950         fi
951
952 ioctlsort_CC = $(CC_FOR_BUILD)
953 ioctlsort_DEFS = $(DEFS)
954 ioctlsort_INCLUDES = $(DEFAULT_INCLUDES) $(INCLUDES)
955 ioctlsort_CPPFLAGS = $(AM_CPPFLAGS_FOR_BUILD) $(CPPFLAGS_FOR_BUILD)
956 ioctlsort_CFLAGS = $(AM_CFLAGS_FOR_BUILD) $(CFLAGS_FOR_BUILD)
957 ioctlsort_LDFLAGS = $(AM_LDFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD)
958
959 ioctls_inc_h = $(wildcard $(srcdir)/$(OS)/$(ARCH)/ioctls_inc*.h)
960 ioctlent_h = $(patsubst $(srcdir)/$(OS)/$(ARCH)/ioctls_inc%,ioctlent%,$(ioctls_inc_h))
961 ioctl_redefs_h = $(filter-out ioctl_redefs0.h,$(subst ioctlent,ioctl_redefs,$(ioctlent_h)))
962
963 ioctl_redefs%.h: ioctlent%.h ioctlent0.h
964         sort $< > $<-t
965         sort ioctlent0.h | comm -23 $<-t - | \
966                 sed -r -n 's/^\{ "([^"]+)", (0x[[:xdigit:]]+) \},$$/#ifdef \1\n# undef \1\n# define \1 \2\n#endif/p' \
967                 > $@-t
968         rm -f $<-t
969         mv $@-t $@
970
971 ioctlent%.h: ioctlsort%
972         ./$< > $@
973
974 # Need to pick up <linux/ioctl.h> definitions *for host* while compiling
975 # ioctlsort *for build*, hence this magic.
976 ioctl_iocdef.i: $(srcdir)/ioctl_iocdef.c
977         $(CPP) -P $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
978                 $(strace_CPPFLAGS) $(CPPFLAGS) $< -o $@
979
980 ioctl_iocdef.h: ioctl_iocdef.i
981         sed -n 's/^DEFINE HOST/#define /p' $< > $@
982
983 ioctlsort%$(BUILD_EXEEXT): ioctlsort%.o
984         $(ioctlsort_CC) $(ioctlsort_CFLAGS) $(ioctlsort_LDFLAGS) $< -o $@
985
986 ioctlsort%.o: ioctls_all%.h ioctl_iocdef.h $(srcdir)/ioctlsort.c
987         $(ioctlsort_CC) $(ioctlsort_DEFS) $(ioctlsort_INCLUDES) $(ioctlsort_CPPFLAGS) $(ioctlsort_CFLAGS) -DIOCTLSORT_INC=\"$<\" -c -o $@ $(srcdir)/ioctlsort.c
988
989 ioctls_all%.h: $(srcdir)/$(OS)/$(ARCH)/ioctls_inc%.h $(srcdir)/$(OS)/$(ARCH)/ioctls_arch%.h
990         cat $^ > $@
991
992 BUILT_SOURCES = $(ioctl_redefs_h) $(ioctlent_h) \
993                 native_printer_decls.h native_printer_defs.h printers.h sen.h sys_func.h .version
994 CLEANFILES    = $(ioctl_redefs_h) $(ioctlent_h) $(mpers_preproc_files) \
995                 ioctl_iocdef.h ioctl_iocdef.i \
996                 native_printer_decls.h native_printer_defs.h printers.h sen.h sys_func.h
997 DISTCLEANFILES = gnu/stubs-32.h gnu/stubs-x32.h
998
999 include scno.am
1000
1001 $(strace_OBJECTS): scno.h
1002
1003 # defines mpers_source_files
1004 include mpers.am
1005 srcdir_mpers_source_files = $(patsubst %,$(srcdir)/%,$(mpers_source_files))
1006 mpers_preproc_files = $(mpers_source_files:.c=.c.mpers.i)
1007
1008 mpers_NAME =
1009 mpers_PREFIX = $(mpers_NAME)_
1010 mpers_DEFS = $(DEFS)
1011 mpers_INCLUDES = $(DEFAULT_INCLUDES) $(INCLUDES)
1012 mpers_CPPFLAGS = $(strace_CPPFLAGS) $(CPPFLAGS)
1013 mpers_sh_opts = $(mpers_DEFS) $(mpers_INCLUDES) $(mpers_CPPFLAGS)
1014 libmpers_CPPFLAGS = $(strace_CPPFLAGS) -DIN_MPERS
1015 libmpers_CFLAGS = $(strace_CFLAGS)
1016
1017 # mpers targets
1018
1019 mpers-m%.stamp: $(srcdir_mpers_source_files) | printers.h
1020         for f in $^; do \
1021                 READELF="$(READELF)" \
1022                 CC="$(CC)" \
1023                 CFLAGS="$(mpers_sh_opts) -DMPERS_IS_$(mpers_NAME)" \
1024                 CPP="$(CPP)" \
1025                 CPPFLAGS="$(mpers_sh_opts) -DIN_MPERS -DMPERS_IS_$(mpers_NAME)" \
1026                 $(srcdir)/mpers.sh $(mpers_NAME) $(mpers_CC_FLAGS) $$f || exit; \
1027         done
1028         > $@
1029
1030 m%_type_defs.h: $(srcdir_mpers_source_files)
1031         for f in $^; do \
1032                 sed -r -n 's/^#[[:space:]]*include DEF_MPERS_TYPE\(([^)]+)\)/#ifdef MPERS_$(mpers_PREFIX)\1\n# define \1 MPERS_$(mpers_PREFIX)\1\n#endif/p' $$f || exit; \
1033         done > $@-t
1034         echo '#undef MPERS_PRINTER_NAME' >> $@-t
1035         echo '#define MPERS_PRINTER_NAME(printer_name) printer_name' >> $@-t
1036         echo '#include "$(mpers_PREFIX)printer_decls.h"' >> $@-t
1037         echo '#include MPERS_$(mpers_PREFIX)IOCTL_MACROS' >> $@-t
1038         mv $@-t $@
1039
1040 m%_funcs.h: $(srcdir_mpers_source_files)
1041         for f in $^; do \
1042                 sed -r -n 's/^SYS_FUNC\(([^)]+)\)/#undef sys_\1\n#define sys_\1 $(mpers_PREFIX)sys_\1/p' $$f || exit; \
1043         done > $@-t && \
1044         echo '#include "sys_func.h"' >> $@-t
1045         mv $@-t $@
1046
1047 # printers
1048
1049 %.c.mpers.i: $(srcdir)/%.c
1050         $(CPP) -P $(mpers_sh_opts) -DIN_MPERS_BOOTSTRAP $< -o $@
1051
1052 mpers_printer_decl_pattern = ^MPERS_PRINTER_DECL\(([^,)]+),[[:space:]]*([^,)]+),[[:space:]]*([^)]+)\)$$
1053
1054 printers.h: $(mpers_preproc_files)
1055         echo '/* Generated by Makefile from $^; do not edit. */' > $@-t
1056         echo 'typedef struct {' >> $@-t
1057         for f in $^; do \
1058                 sed -r -n 's/$(mpers_printer_decl_pattern)/ \1 (*\2)(\3);\n#define \2 MPERS_PRINTER_NAME(\2)\n/p' $$f \
1059                 || exit; \
1060         done >> $@-t
1061         echo '} struct_printers;' >> $@-t
1062         echo 'extern const struct_printers *printers;' >> $@-t
1063         echo '#define MPERS_PRINTER_NAME(printer_name) printers->printer_name' >> $@-t
1064         mv $@-t $@
1065
1066 %_printer_decls.h: $(mpers_preproc_files)
1067         echo '/* Generated by Makefile from $^; do not edit. */' > $@-t
1068         for f in $^; do \
1069                 sed -r -n 's/$(mpers_printer_decl_pattern)/extern \1 $(mpers_PREFIX)\2(\3);/p' $$f \
1070                 || exit; \
1071         done >> $@-t
1072         mv $@-t $@
1073
1074 %_printer_defs.h: $(mpers_preproc_files)
1075         echo '/* Generated by Makefile from $^; do not edit. */' > $@-t
1076         for f in $^; do \
1077                 sed -r -n 's/$(mpers_printer_decl_pattern)/.\2 = $(mpers_PREFIX)\2,/p' $$f \
1078                 || exit; \
1079         done >> $@-t
1080         mv $@-t $@
1081
1082 native_printer_decls.h native_printer_defs.h: mpers_PREFIX =
1083
1084 if HAVE_M32_MPERS
1085
1086 strace_LDADD += libmpers-m32.a
1087 noinst_LIBRARIES += libmpers-m32.a
1088 libmpers_m32_a_SOURCES = $(mpers_source_files)
1089 libmpers_m32_a_CPPFLAGS = $(libmpers_CPPFLAGS) -DMPERS_IS_m32 -I$(builddir)/mpers-m32
1090 libmpers_m32_a_CFLAGS = $(libmpers_CFLAGS)
1091 mpers_m32_targets = mpers-m32.stamp m32_type_defs.h m32_funcs.h m32_printer_decls.h m32_printer_defs.h
1092
1093 BUILT_SOURCES += $(mpers_m32_targets)
1094 CLEANFILES    += $(mpers_m32_targets)
1095
1096 $(mpers_m32_targets): mpers_NAME = m32
1097 $(mpers_m32_targets): mpers_CC_FLAGS = @cc_flags_m32@
1098
1099 endif # HAVE_M32_MPERS
1100
1101 if HAVE_MX32_MPERS
1102
1103 strace_LDADD += libmpers-mx32.a
1104 noinst_LIBRARIES += libmpers-mx32.a
1105 libmpers_mx32_a_SOURCES = $(mpers_source_files)
1106 libmpers_mx32_a_CPPFLAGS = $(libmpers_CPPFLAGS) -DMPERS_IS_mx32 -I$(builddir)/mpers-mx32
1107 libmpers_mx32_a_CFLAGS = $(libmpers_CFLAGS)
1108 mpers_mx32_targets = mpers-mx32.stamp mx32_type_defs.h mx32_funcs.h mx32_printer_decls.h mx32_printer_defs.h
1109
1110 BUILT_SOURCES += $(mpers_mx32_targets)
1111 CLEANFILES    += $(mpers_mx32_targets)
1112
1113 $(mpers_mx32_targets): mpers_NAME = mx32
1114 $(mpers_mx32_targets): mpers_CC_FLAGS = @cc_flags_mx32@
1115
1116 endif # HAVE_MX32_MPERS
1117
1118 clean-local:
1119         -rm -rf mpers-m32 mpers-mx32
1120
1121 if MAINTAINER_MODE
1122
1123 gen_changelog_start_date = 2009-07-08 20:00
1124 $(srcdir)/ChangeLog: $(srcdir)/gitlog-to-changelog $(srcdir)/Makefile.in \
1125                      $(srcdir)/.version
1126         @rm -f $@.new
1127         (cd $(srcdir); \
1128          ./gitlog-to-changelog --append-dot \
1129            --since='$(gen_changelog_start_date)'; \
1130          echo; echo; echo 'See ChangeLog-CVS for older changes.' \
1131         ) > $@.new
1132         chmod 444 $@.new
1133         mv -f $@.new $@
1134
1135 $(srcdir)/CREDITS: $(srcdir)/CREDITS.in $(srcdir)/.mailmap \
1136                    $(srcdir)/Makefile.in $(srcdir)/.version
1137         $(AM_V_GEN)                                                     \
1138         (                                                               \
1139           cd $(srcdir);                                                 \
1140           sed '/^##/,$$d' CREDITS.in;                                   \
1141           sed -n '1,/^##>/d; s/   */\t/; s/^./&/p' CREDITS.in           \
1142             | maint/gen-contributors-list.sh - -e HEAD --initial        \
1143             | sed 's/\t/ /g; s/^/\t/'                                   \
1144         ) > $@-t && mv $@-t $@
1145
1146 export TAR_OPTIONS = --owner=0 --group=0 --numeric-owner --mode=go-w,go+rX
1147
1148 endif