Whamcloud - gitweb
4a8075521eb68b40f3c8abc863fc50e7acc33556
[fs/lustre-release.git] / lustre / lvfs / autoMakefile.am
1 # Copyright (C) 2001  Cluster File Systems, Inc.
2 #
3 # This code is issued under the GNU General Public License.
4 # See the file COPYING in this distribution
5
6 if LIBLUSTRE
7 noinst_LIBRARIES = liblvfs.a
8 liblvfs_a_SOURCES = lvfs_userfs.c llog_lvfs.c llog_cat.c llog.c
9 liblvfs_a_CFLAGS = $(LLCFLAGS)
10 liblvfs_a_CPPFLAGS = $(LLCPPFLAGS)
11
12 #if MYSQL
13 #liblvfs_a_SOURCES += lvfs_user_mysql.c
14 #endif
15 endif
16
17 if MODULES
18
19 modulefs_DATA = lvfs$(KMODEXT) fsfilt_$(BACKINGFS)$(KMODEXT) fsfilt_smfs$(KMODEXT)
20
21 sources: fsfilt_$(BACKINGFS).c fsfilt_smfs.c fsfilt_snap_$(BACKINGFS).c
22         touch sources
23
24 fsfilt_extN.c: fsfilt_ext3.c
25         sed -e "s/EXT3/EXTN/g" -e "s/ext3/extN/g" $< > $@
26
27 fsfilt_smfs.c:
28         $< > $@
29
30 ldiskfs_sed_flags = \
31         -e "s/dx_hash_info/ext3_dx_hash_info/g" \
32         -e "s/dir_private_info/ext3_dir_private_info/g" \
33         -e "s/DX_HASH/EXT3_DX_HASH/g" \
34         -e "s/reserve_window/ext3_reserve_window/g" \
35         -e "s/rsv_window_add/ext3_rsv_window_add/g" \
36         -e "s/EXT3/LDISKFS/g" -e "s/ext3/ldiskfs/g"
37
38 fsfilt_ldiskfs.c: fsfilt_ext3.c
39         sed $(strip $(ldiskfs_sed_flags)) $< > $@
40
41 fsfilt_snap_ldiskfs.c: fsfilt_snap_ext3.c
42         sed $(strip $(ldiskfs_sed_flags)) $< > $@
43
44 endif # MODULES
45
46 DIST_SOURCES = fsfilt.c fsfilt_ext3.c fsfilt_smfs.c fsfilt_reiserfs.c \
47         lvfs_common.c lvfs_internal.h lvfs_linux.c llog.c llog_cat.c \
48         llog_lvfs.c lvfs_userfs.c fsfilt_snap_ext3.c
49
50 MOSTLYCLEANFILES = *.o *.ko *.mod.c
51 CLEANFILES = fsfilt-*.c fsfilt_ldiskfs.c fsfilt_extN.c sources