]>
Commit | Line | Data |
---|---|---|
95b1e505 DW |
1 | # |
2 | # Copyright (C) 2018 Oracle. All Rights Reserved. | |
3 | # | |
4 | ||
5 | TOPDIR = .. | |
6 | include $(TOPDIR)/include/builddefs | |
7 | ||
8 | # On linux we get fsmap from the system or define it ourselves | |
9 | # so include this based on platform type. If this reverts to only | |
10 | # the autoconf check w/o local definition, change to testing HAVE_GETFSMAP | |
11 | SCRUB_PREREQS=$(PKG_PLATFORM) | |
12 | ||
13 | ifeq ($(SCRUB_PREREQS),linux) | |
14 | LTCOMMAND = xfs_scrub | |
15 | INSTALL_SCRUB = install-scrub | |
16 | endif # scrub_prereqs | |
17 | ||
18 | HFILES = \ | |
19 | common.h \ | |
d11cc69e | 20 | counter.h \ |
a555a1f4 | 21 | disk.h \ |
c6eb0ff2 | 22 | filemap.h \ |
604dd334 | 23 | fscounters.h \ |
372d4ba9 | 24 | inodes.h \ |
fd7d73c0 | 25 | scrub.h \ |
bc94c5d6 | 26 | spacemap.h \ |
95b1e505 DW |
27 | xfs_scrub.h |
28 | ||
29 | CFILES = \ | |
30 | common.c \ | |
d11cc69e | 31 | counter.c \ |
a555a1f4 | 32 | disk.c \ |
c6eb0ff2 | 33 | filemap.c \ |
604dd334 | 34 | fscounters.c \ |
372d4ba9 | 35 | inodes.c \ |
50a573a7 | 36 | phase1.c \ |
e758ad01 | 37 | phase2.c \ |
fa16b376 | 38 | phase3.c \ |
c4892e76 | 39 | phase5.c \ |
fd7d73c0 | 40 | scrub.c \ |
bc94c5d6 | 41 | spacemap.c \ |
95b1e505 DW |
42 | xfs_scrub.c |
43 | ||
44 | LLDLIBS += $(LIBHANDLE) $(LIBFROG) $(LIBPTHREAD) | |
45 | LTDEPENDENCIES += $(LIBHANDLE) $(LIBFROG) | |
46 | LLDFLAGS = -static | |
47 | ||
173a0283 DW |
48 | ifeq ($(HAVE_MALLINFO),yes) |
49 | LCFLAGS += -DHAVE_MALLINFO | |
50 | endif | |
51 | ||
50a573a7 DW |
52 | ifeq ($(HAVE_SYNCFS),yes) |
53 | LCFLAGS += -DHAVE_SYNCFS | |
54 | endif | |
55 | ||
95b1e505 DW |
56 | default: depend $(LTCOMMAND) |
57 | ||
58 | include $(BUILDRULES) | |
59 | ||
60 | install: default $(INSTALL_SCRUB) | |
61 | ||
62 | install-scrub: | |
63 | $(INSTALL) -m 755 -d $(PKG_ROOT_SBIN_DIR) | |
64 | $(LTINSTALL) -m 755 $(LTCOMMAND) $(PKG_ROOT_SBIN_DIR) | |
65 | ||
66 | install-dev: | |
67 | ||
68 | -include .dep |