blob: 7efe39c664d9400ce9ac6a3c3d732180ac0e4589 [file] [log] [blame]
Aditya Kalif239fef2011-07-20 11:40:02 -07001# Makefile for the QUOTA library
2#
3
4srcdir = @srcdir@
5top_srcdir = @top_srcdir@
6VPATH = @srcdir@
7top_builddir = ../..
8my_dir = lib/quota
9INSTALL = @INSTALL@
10
11@MCONFIG@
12
13all::
14
Aditya Kalia86d55d2011-11-14 10:55:54 -050015OBJS= mkquota.o quotaio.o quotaio_v2.o quotaio_tree.o dict.o
Aditya Kalif239fef2011-07-20 11:40:02 -070016
Aditya Kalia86d55d2011-11-14 10:55:54 -050017SRCS= $(srcdir)/mkquota.c \
Aditya Kalif239fef2011-07-20 11:40:02 -070018 $(srcdir)/quotaio.c \
19 $(srcdir)/quotaio_tree.c \
20 $(srcdir)/quotaio_v2.c \
21 $(srcdir)/../../e2fsck/dict.c
22
23LIBRARY= libquota
24LIBDIR= quota
25
Theodore Ts'o8f9d7082011-09-19 13:39:38 -040026#ELF_VERSION = 1.0
27#ELF_SO_VERSION = 1
28#ELF_IMAGE = libquota
29#ELF_MYDIR = quota
30#ELF_INSTALL_DIR = $(root_libdir)
Theodore Ts'od5aa6a82012-08-04 16:56:55 -040031#ELF_OTHER_LIBS = -lext2fs
Aditya Kalif239fef2011-07-20 11:40:02 -070032
Theodore Ts'o8f9d7082011-09-19 13:39:38 -040033#BSDLIB_VERSION = 1.0
34#BSDLIB_IMAGE = libquota
35#BSDLIB_MYDIR = quota
36#BSDLIB_INSTALL_DIR = $(root_libdir)
Aditya Kalif239fef2011-07-20 11:40:02 -070037
38@MAKEFILE_LIBRARY@
Theodore Ts'o8f9d7082011-09-19 13:39:38 -040039#MAKEFILE_ELF#
40#MAKEFILE_BSDLIB#
Aditya Kalif239fef2011-07-20 11:40:02 -070041@MAKEFILE_PROFILE@
Aditya Kalif239fef2011-07-20 11:40:02 -070042
43.c.o:
44 $(E) " CC $<"
45 $(Q) $(CC) $(ALL_CFLAGS) -c $< -o $@
Darrick J. Wong832cb612013-10-11 23:02:12 -040046 $(Q) $(CHECK_CMD) $(ALL_CFLAGS) $<
Darrick J. Wonga46300f2014-05-11 18:32:07 -040047 $(Q) $(CPPCHECK_CMD) $(CPPFLAGS) $<
Aditya Kalif239fef2011-07-20 11:40:02 -070048@PROFILE_CMT@ $(Q) $(CC) $(ALL_CFLAGS) -g -pg -o profiled/$*.o -c $<
Theodore Ts'o8f9d7082011-09-19 13:39:38 -040049#ELF_CMT# $(Q) $(CC) $(ALL_CFLAGS) -fPIC -o elfshared/$*.o -c $<
50#BSDLIB_CMT# $(Q) $(CC) $(ALL_CFLAGS) $(BSDLIB_PIC_FLAG) -o pic/$*.o -c $<
Aditya Kalif239fef2011-07-20 11:40:02 -070051
Aditya Kalif239fef2011-07-20 11:40:02 -070052dict.o:
53 $(E) " CC $<"
54 $(Q) $(CC) -c $(ALL_CFLAGS) $(top_srcdir)/e2fsck/dict.c -o $@
55@PROFILE_CMT@ $(Q) $(CC) $(ALL_CFLAGS) -g -pg -o profiled/dict.o -c \
56@PROFILE_CMT@ $(top_srcdir)/e2fsck/dict.c
Theodore Ts'o8f9d7082011-09-19 13:39:38 -040057#ELF_CMT# $(Q) $(CC) $(ALL_CFLAGS) -fPIC -o elfshared/$*.o -c \
58#ELF_CMT# $(top_srcdir)/e2fsck/dict.c
59#BSDLIB_CMT# $(Q) $(CC) $(ALL_CFLAGS) $(BSDLIB_PIC_FLAG) -o pic/$*.o -c \
60#BSDLIB_CMT# $(top_srcdir)/e2fsck/dict.c
Aditya Kalif239fef2011-07-20 11:40:02 -070061
62installdirs::
Aditya Kalif239fef2011-07-20 11:40:02 -070063
Theodore Ts'od37178b2014-05-10 18:55:20 -040064install:: all
Aditya Kalif239fef2011-07-20 11:40:02 -070065
66uninstall::
Aditya Kalif239fef2011-07-20 11:40:02 -070067
68clean::
Eric Sandeen2f8d0252014-04-17 17:05:38 -050069 $(RM) -f \#* *.s *.o *.a *~ *.bak core profiled/*
Aditya Kalif239fef2011-07-20 11:40:02 -070070 $(RM) -f ../libquota.a ../libquota_p.a $(SMANPAGES)
71
72#check:: tst_uuid
73# LD_LIBRARY_PATH=$(LIB) DYLD_LIBRARY_PATH=$(LIB) ./tst_uuid
74
75mostlyclean:: clean
76distclean:: clean
Theodore Ts'od37178b2014-05-10 18:55:20 -040077 $(RM) -f .depend Makefile \
Aditya Kalif239fef2011-07-20 11:40:02 -070078 $(srcdir)/TAGS $(srcdir)/Makefile.in.old
79
80#
81# Hack to parallel makes recognize dependencies correctly.
82#
83../../lib/libquota.a: libquota.a
84../../lib/libquota.so: image
85../../lib/libquota.dylib: image
86
87$(OBJS):
88
89# +++ Dependency line eater +++
90#
91# Makefile dependencies follow. This must be the last section in
92# the Makefile.in file
93#
Theodore Ts'od1154eb2011-09-18 17:34:37 -040094mkquota.o: $(srcdir)/mkquota.c $(top_builddir)/lib/config.h \
95 $(top_builddir)/lib/dirpaths.h $(top_srcdir)/lib/ext2fs/ext2_fs.h \
Aditya Kalif239fef2011-07-20 11:40:02 -070096 $(top_builddir)/lib/ext2fs/ext2_types.h $(top_srcdir)/lib/ext2fs/ext2fs.h \
97 $(top_srcdir)/lib/ext2fs/ext3_extents.h $(top_srcdir)/lib/et/com_err.h \
98 $(top_srcdir)/lib/ext2fs/ext2_io.h $(top_builddir)/lib/ext2fs/ext2_err.h \
99 $(top_srcdir)/lib/ext2fs/ext2_ext_attr.h $(top_srcdir)/lib/ext2fs/bitops.h \
Jan Kara2ae58b62012-06-04 12:51:55 -0400100 $(top_srcdir)/lib/e2p/e2p.h $(srcdir)/quotaio.h $(srcdir)/dqblk_v2.h \
Theodore Ts'od37178b2014-05-10 18:55:20 -0400101 $(srcdir)/quotaio_tree.h $(top_srcdir)/lib/../e2fsck/dict.h \
102 $(srcdir)/quotaio_v2.h $(srcdir)/common.h
Theodore Ts'od1154eb2011-09-18 17:34:37 -0400103quotaio.o: $(srcdir)/quotaio.c $(top_builddir)/lib/config.h \
Theodore Ts'oc714d022014-01-30 18:48:23 -0500104 $(top_builddir)/lib/dirpaths.h $(srcdir)/common.h \
105 $(top_builddir)/lib/ext2fs/ext2_types.h $(srcdir)/quotaio.h \
Theodore Ts'od37178b2014-05-10 18:55:20 -0400106 $(top_srcdir)/lib/ext2fs/ext2_fs.h $(top_srcdir)/lib/ext2fs/ext2fs.h \
Theodore Ts'oc714d022014-01-30 18:48:23 -0500107 $(top_srcdir)/lib/ext2fs/ext3_extents.h $(top_srcdir)/lib/et/com_err.h \
108 $(top_srcdir)/lib/ext2fs/ext2_io.h $(top_builddir)/lib/ext2fs/ext2_err.h \
109 $(top_srcdir)/lib/ext2fs/ext2_ext_attr.h $(top_srcdir)/lib/ext2fs/bitops.h \
Theodore Ts'od37178b2014-05-10 18:55:20 -0400110 $(srcdir)/dqblk_v2.h $(srcdir)/quotaio_tree.h \
111 $(top_srcdir)/lib/../e2fsck/dict.h
Theodore Ts'oc714d022014-01-30 18:48:23 -0500112quotaio_tree.o: $(srcdir)/quotaio_tree.c $(top_builddir)/lib/config.h \
113 $(top_builddir)/lib/dirpaths.h $(srcdir)/common.h \
114 $(top_builddir)/lib/ext2fs/ext2_types.h $(srcdir)/quotaio_tree.h \
Theodore Ts'od37178b2014-05-10 18:55:20 -0400115 $(srcdir)/quotaio.h $(top_srcdir)/lib/ext2fs/ext2_fs.h \
116 $(top_srcdir)/lib/ext2fs/ext2fs.h $(top_srcdir)/lib/ext2fs/ext3_extents.h \
Aditya Kalif239fef2011-07-20 11:40:02 -0700117 $(top_srcdir)/lib/et/com_err.h $(top_srcdir)/lib/ext2fs/ext2_io.h \
118 $(top_builddir)/lib/ext2fs/ext2_err.h \
119 $(top_srcdir)/lib/ext2fs/ext2_ext_attr.h $(top_srcdir)/lib/ext2fs/bitops.h \
Theodore Ts'od37178b2014-05-10 18:55:20 -0400120 $(srcdir)/dqblk_v2.h $(top_srcdir)/lib/../e2fsck/dict.h
Theodore Ts'od1154eb2011-09-18 17:34:37 -0400121quotaio_v2.o: $(srcdir)/quotaio_v2.c $(top_builddir)/lib/config.h \
Theodore Ts'oc714d022014-01-30 18:48:23 -0500122 $(top_builddir)/lib/dirpaths.h $(srcdir)/common.h \
123 $(top_builddir)/lib/ext2fs/ext2_types.h $(srcdir)/quotaio_v2.h \
Theodore Ts'od37178b2014-05-10 18:55:20 -0400124 $(srcdir)/quotaio.h $(top_srcdir)/lib/ext2fs/ext2_fs.h \
125 $(top_srcdir)/lib/ext2fs/ext2fs.h $(top_srcdir)/lib/ext2fs/ext3_extents.h \
Theodore Ts'oc714d022014-01-30 18:48:23 -0500126 $(top_srcdir)/lib/et/com_err.h $(top_srcdir)/lib/ext2fs/ext2_io.h \
127 $(top_builddir)/lib/ext2fs/ext2_err.h \
Jan Kara2ae58b62012-06-04 12:51:55 -0400128 $(top_srcdir)/lib/ext2fs/ext2_ext_attr.h $(top_srcdir)/lib/ext2fs/bitops.h \
Theodore Ts'od37178b2014-05-10 18:55:20 -0400129 $(srcdir)/dqblk_v2.h $(srcdir)/quotaio_tree.h \
130 $(top_srcdir)/lib/../e2fsck/dict.h
Theodore Ts'od1154eb2011-09-18 17:34:37 -0400131dict.o: $(srcdir)/../../e2fsck/dict.c $(top_builddir)/lib/config.h \
132 $(top_builddir)/lib/dirpaths.h $(srcdir)/../../e2fsck/dict.h