]>
Commit | Line | Data |
---|---|---|
8c392629 JE |
1 | ACLOCAL_AMFLAGS = -I config |
2 | ||
47a4a6fd TF |
3 | include config/rpm.am |
4 | include config/deb.am | |
5 | include config/tgz.am | |
c9c0d073 | 6 | |
f3757573 | 7 | SUBDIRS = include rpm |
c9c0d073 | 8 | if CONFIG_USER |
3c67d83a | 9 | SUBDIRS += udev etc man scripts lib tests cmd contrib |
c9c0d073 BB |
10 | endif |
11 | if CONFIG_KERNEL | |
fd7fd5eb | 12 | SUBDIRS += module |
775f2d34 | 13 | |
3cd33ffc | 14 | extradir = @prefix@/src/zfs-$(VERSION) |
775f2d34 BB |
15 | extra_HEADERS = zfs.release.in zfs_config.h.in |
16 | ||
3cd33ffc | 17 | kerneldir = @prefix@/src/zfs-$(VERSION)/$(LINUX_VERSION) |
775f2d34 | 18 | nodist_kernel_HEADERS = zfs.release zfs_config.h module/$(LINUX_SYMBOLS) |
c9c0d073 | 19 | endif |
c9c0d073 | 20 | |
8160dd9a | 21 | AUTOMAKE_OPTIONS = foreign |
f3757573 | 22 | EXTRA_DIST = autogen.sh copy-builtin |
c9c0d073 | 23 | EXTRA_DIST += config/config.awk config/rpm.am config/deb.am config/tgz.am |
e07b579b | 24 | EXTRA_DIST += META DISCLAIMER COPYRIGHT README.markdown OPENSOLARIS.LICENSE |
c9c0d073 BB |
25 | |
26 | distclean-local:: | |
27 | -$(RM) -R autom4te*.cache | |
28 | -find . \( -name SCCS -o -name BitKeeper -o -name .svn -o -name CVS \ | |
29 | -o -name .pc -o -name .hg -o -name .git \) -prune -o \ | |
30 | \( -name '*.orig' -o -name '*.rej' -o -name '*~' \ | |
31 | -o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \ | |
1ae93745 | 32 | -o -name '.*.rej' -o -name '.script-config' -o -size 0 \ |
c9c0d073 BB |
33 | -o -name '*%' -o -name '.*.cmd' -o -name 'core' \ |
34 | -o -name 'Makefile' -o -name 'Module.symvers' \ | |
1ae93745 | 35 | -o -name '*.order' -o -name '*.markers' \) \ |
c9c0d073 BB |
36 | -type f -print | xargs $(RM) |
37 | ||
f6fb7651 BB |
38 | dist-hook: |
39 | sed -i 's/Release:[[:print:]]*/Release: $(RELEASE)/' \ | |
40 | $(distdir)/META | |
41 | ||
46bb91e1 | 42 | checkstyle: cstyle shellcheck flake8 |
c11cd7f9 TF |
43 | |
44 | cstyle: | |
351a26dd | 45 | @find ${top_srcdir} -name '*.[hc]' ! -name 'zfs_config.*' \ |
02730c33 | 46 | ! -name '*.mod.c' -type f -exec scripts/cstyle.pl -cpP {} \+ |
a35beedf | 47 | |
c11cd7f9 TF |
48 | shellcheck: |
49 | @if type shellcheck > /dev/null 2>&1; then \ | |
c552fbc5 GDN |
50 | shellcheck --exclude=SC1090 --format gcc scripts/paxcheck.sh \ |
51 | scripts/zloop.sh \ | |
52 | scripts/zfs-tests.sh \ | |
53 | scripts/zfs.sh; \ | |
54 | (find cmd/zed/zed.d/*.sh -type f) | \ | |
c11cd7f9 TF |
55 | grep -v 'zfs-script-config' | \ |
56 | while read file; do \ | |
c552fbc5 | 57 | shellcheck --exclude=SC1090 --format gcc "$$file"; \ |
c11cd7f9 TF |
58 | done; \ |
59 | fi | |
60 | ||
f26eb428 | 61 | lint: cppcheck paxcheck |
b64e02e5 BB |
62 | |
63 | cppcheck: | |
64 | @if type cppcheck > /dev/null 2>&1; then \ | |
589bb918 GDN |
65 | cppcheck --inline-suppr --quiet --force --error-exitcode=2 \ |
66 | ${top_srcdir}; \ | |
b64e02e5 BB |
67 | fi |
68 | ||
f26eb428 JZ |
69 | paxcheck: |
70 | @if type scanelf > /dev/null 2>&1; then \ | |
71 | scripts/paxcheck.sh ${top_srcdir}; \ | |
72 | fi | |
73 | ||
46bb91e1 GDN |
74 | flake8: |
75 | @if type flake8 > /dev/null 2>&1; then \ | |
76 | flake8 ${top_srcdir}; \ | |
77 | fi | |
78 | ||
c9c0d073 | 79 | ctags: |
47a4a6fd | 80 | $(RM) tags |
c9c0d073 BB |
81 | find $(top_srcdir) -name .git -prune -o -name '*.[hc]' | xargs ctags |
82 | ||
83 | etags: | |
47a4a6fd | 84 | $(RM) TAGS |
c9c0d073 BB |
85 | find $(top_srcdir) -name .pc -prune -o -name '*.[hc]' | xargs etags -a |
86 | ||
87 | tags: ctags etags | |
88 | ||
89 | pkg: @DEFAULT_PACKAGE@ | |
f3757573 | 90 | pkg-kmod: @DEFAULT_PACKAGE@-kmod |
c9c0d073 | 91 | pkg-utils: @DEFAULT_PACKAGE@-utils |