]> sourceware.org Git - lvm2.git/commitdiff
make: cflow target works again
authorZdenek Kabelac <zkabelac@redhat.com>
Fri, 19 Mar 2021 22:10:55 +0000 (23:10 +0100)
committerZdenek Kabelac <zkabelac@redhat.com>
Fri, 19 Mar 2021 23:05:01 +0000 (00:05 +0100)
Restored 'make cflow' functinality.
Produces some quick referece of function chaining and usage.

14 files changed:
daemons/cmirrord/Makefile.in
daemons/dmeventd/Makefile.in
daemons/dmeventd/plugins/mirror/Makefile.in
daemons/dmeventd/plugins/raid/Makefile.in
daemons/dmeventd/plugins/thin/Makefile.in
daemons/dmeventd/plugins/vdo/Makefile.in
daemons/lvmlockd/Makefile.in
daemons/lvmpolld/Makefile.in
lib/Makefile.in
libdm/Makefile.in
libdm/dm-tools/Makefile.in
libdm/make.tmpl.in
make.tmpl.in
tools/Makefile.in

index 301e6c6a2fbbe53dde47456e96e7403816d296dc..8f68ba91c2eeb9c1a79845c5c9af29d21c6ab2a8 100644 (file)
@@ -22,6 +22,9 @@ SOURCES = clogd.c cluster.c compat.c functions.c link_mon.c local.c logging.c
 
 TARGETS = cmirrord
 
+CFLOW_SOURCES = $(addprefix $(srcdir)/, $(SOURCES))
+CFLOW_TARGET := $(TARGETS)
+
 include $(top_builddir)/make.tmpl
 
 LMLIBS += $(CPG_LIBS)
index 99e4a816f9f6d59b5b7936b5c365ee57e38972bb..c737ca40d162af4624d0ea7815cc3294201cb462 100644 (file)
 srcdir = @srcdir@
 top_srcdir = @top_srcdir@
 top_builddir = @top_builddir@
+abs_srcdir = @abs_srcdir@
 
 SOURCES = libdevmapper-event.c
 SOURCES2 = dmeventd.c
 
 TARGETS = dmeventd
+CFLOW_SOURCES = $(addprefix $(srcdir)/, $(SOURCES) $(SOURCES2) \
+       plugins/lvm2/dmeventd_lvm.c \
+       plugins/mirror/dmeventd_mirror.c \
+       plugins/raid/dmeventd_raid.c \
+       plugins/snapshot/dmeventd_snapshot.c \
+       plugins/thin/dmeventd_thin.c \
+       plugins/vdo/dmeventd_vdo.c \
+       )
+CFLOW_TARGET := $(TARGETS)
 
 .PHONY: install_lib_dynamic install_lib_static install_include \
        install_pkgconfig install_dmeventd_dynamic install_dmeventd_static \
@@ -46,7 +56,6 @@ endif
 
 CFLOW_LIST = $(SOURCES)
 CFLOW_LIST_TARGET = $(LIB_NAME).cflow
-CFLOW_TARGET = dmeventd
 
 EXPORTED_HEADER = $(srcdir)/libdevmapper-event.h
 EXPORTED_FN_PREFIX = dm_event
@@ -73,14 +82,6 @@ ifeq ("@PKGCONFIG@", "yes")
   INSTALL_LIB_TARGETS += install_pkgconfig
 endif
 
-ifneq ("$(CFLOW_CMD)", "")
-CFLOW_SOURCES = $(addprefix $(srcdir)/, $(SOURCES))
--include $(top_builddir)/lib/liblvm-internal.cflow
--include $(top_builddir)/lib/liblvm2cmd.cflow
--include $(top_builddir)/daemons/dmeventd/$(LIB_NAME).cflow
--include $(top_builddir)/daemons/dmeventd/plugins/mirror/$(LIB_NAME)-lvm2mirror.cflow
-endif
-
 install_include: $(srcdir)/libdevmapper-event.h
        @echo "    [INSTALL] $(<F)"
        $(Q) $(INSTALL_DATA) -D $< $(includedir)/$(<F)
index 62d94c996a5e4555c3f69a414236abd17bd1e4d2..1552d9746ed7e02e756411fa7656c949387215d6 100644 (file)
@@ -25,9 +25,6 @@ LIB_NAME = libdevmapper-event-lvm2mirror
 LIB_SHARED = $(LIB_NAME).$(LIB_SUFFIX)
 LIB_VERSION = $(LIB_VERSION_LVM)
 
-CFLOW_LIST = $(SOURCES)
-CFLOW_LIST_TARGET = $(LIB_NAME).cflow
-
 include $(top_builddir)/make.tmpl
 
 install_lvm2: install_dm_plugin
index abc935d457e2aa6e9c03459b6f4de490058d0da5..2082351c8d6e7b43428fe64694f8284ded8d5dd4 100644 (file)
@@ -24,9 +24,6 @@ LIB_NAME = libdevmapper-event-lvm2raid
 LIB_SHARED = $(LIB_NAME).$(LIB_SUFFIX)
 LIB_VERSION = $(LIB_VERSION_LVM)
 
-CFLOW_LIST = $(SOURCES)
-CFLOW_LIST_TARGET = $(LIB_NAME).cflow
-
 include $(top_builddir)/make.tmpl
 
 install_lvm2: install_dm_plugin
index c1cbee792e6ce00b692e81896a295073fd847eb4..b98e426366f6d9231f45fbe894b6943c6a35ffdb 100644 (file)
@@ -24,9 +24,6 @@ LIB_NAME = libdevmapper-event-lvm2thin
 LIB_SHARED = $(LIB_NAME).$(LIB_SUFFIX)
 LIB_VERSION = $(LIB_VERSION_LVM)
 
-CFLOW_LIST = $(SOURCES)
-CFLOW_LIST_TARGET = $(LIB_NAME).cflow
-
 include $(top_builddir)/make.tmpl
 
 install_lvm2: install_dm_plugin
index 84adb7445db6712f9a7aaad0477db417e602b2f4..44942ea2db24fd55439d185d3ec9a2e145a00732 100644 (file)
@@ -24,9 +24,6 @@ LIB_NAME = libdevmapper-event-lvm2vdo
 LIB_SHARED = $(LIB_NAME).$(LIB_SUFFIX)
 LIB_VERSION = $(LIB_VERSION_LVM)
 
-CFLOW_LIST = $(SOURCES)
-CFLOW_LIST_TARGET = $(LIB_NAME).cflow
-
 include $(top_builddir)/make.tmpl
 
 install_lvm2: install_dm_plugin
index bd577d1e6a742c6cce9f9396cb5d17c358f5b54c..ec5d5750a9c4690729c25d5977e55a14641729a0 100644 (file)
@@ -34,6 +34,9 @@ SOURCES2 = lvmlockctl.c
 
 TARGETS = lvmlockd lvmlockctl
 
+CFLOW_SOURCES = $(addprefix $(srcdir)/, $(SOURCES))
+CFLOW_TARGET = lvmlockd
+
 .PHONY: install_lvmlockd
 
 include $(top_builddir)/make.tmpl
index 05b12ff2c0ad591c05449393a17e6bfc971cff1c..3e85644d74b1e4a49a6e241fd95d7fa35b6c718b 100644 (file)
@@ -19,11 +19,10 @@ SOURCES = lvmpolld-core.c lvmpolld-data-utils.c lvmpolld-cmd-utils.c
 
 TARGETS = lvmpolld
 
-.PHONY: install_lvmpolld
+CFLOW_SOURCES = $(addprefix $(srcdir)/, $(SOURCES))
+CFLOW_TARGET := $(TARGETS)
 
-CFLOW_LIST = $(SOURCES)
-CFLOW_LIST_TARGET = $(LIB_NAME).cflow
-CFLOW_TARGET = lvmpolld
+.PHONY: install_lvmpolld
 
 include $(top_builddir)/make.tmpl
 
index 3409cbd8c16598148d4dc19f0534e16f65b69d91..900ae2f839a15182c9927af7543bc42d8915286e 100644 (file)
@@ -15,6 +15,7 @@
 srcdir = @srcdir@
 top_srcdir = @top_srcdir@
 top_builddir = @top_builddir@
+abs_srcdir = @abs_srcdir@
 
 SOURCES =\
        activate/activate.c \
index e9bb5ae2fb2a9fc46e6c49541a3ed2dad5a4b45a..12fec06b432cefa41ee8e47ebea7f1ff0bd8015b 100644 (file)
@@ -15,6 +15,7 @@
 srcdir = @srcdir@
 top_srcdir = @top_srcdir@
 top_builddir = @top_builddir@
+abs_srcdir = @abs_srcdir@
 
 SUBDIRS=dm-tools
 
index 0b2ef960545872a2936df7c461c343f0a018d2a5..8fbdfc1521ea11176009fed585d3936d49bb94ad 100644 (file)
@@ -20,6 +20,11 @@ all: device-mapper
 
 SOURCES2 = dmsetup.c
 TARGETS_DM = dmsetup
+
+CFLOW_SOURCES = $(addprefix $(srcdir)/, $(SOURCES2))
+CFLOW_TARGET := $(TARGETS_DM)
+-include $(top_builddir)/libdm/libdevmapper.cflow
+
 install_device-mapper: install_dmsetup_dynamic
 
 ifeq ("@STATIC_LINK@", "yes")
index 549ef79d9091cd3103aa871c1ada2383bf400d92..70edcf91dad2fb7193feb9bad8ace371be655093 100644 (file)
@@ -347,8 +347,7 @@ $(SUBDIRS.generate):
 ifneq ("$(CFLOW_LIST_TARGET)", "")
 CLEAN_CFLOW += $(CFLOW_LIST_TARGET)
 $(CFLOW_LIST_TARGET): $(CFLOW_LIST)
-       echo "CFLOW_SOURCES += $(addprefix \
-               \$$(top_srcdir)$(subst $(top_srcdir),,$(srcdir))/, $(CFLOW_LIST))" > $@
+       echo "CFLOW_SOURCES += $(addprefix $(abs_srcdir)/, $(CFLOW_LIST))" > $@
 cflow: $(CFLOW_LIST_TARGET)
 endif
 
@@ -362,23 +361,22 @@ CLEAN_CFLOW += \
 
 ifneq ("$(CFLOW_CMD)", "")
 CFLOW_FLAGS +=\
- --cpp="$(CC) -E" \
+ --cpp="$(CC) -E $(INCLUDES) $(VALGRIND_CFLAGS) $(BLKID_CFLAGS) $(DEFS) \
+ -I$(top_srcdir)/libdm/ioctl \
+ -I$(top_srcdir)/libdm" \
  --symbol _ISbit:wrapper \
  --symbol __attribute__:wrapper \
- --symbol __const__:wrapper \
  --symbol __const:type \
- --symbol __restrict:type \
+ --symbol __const__:wrapper \
  --symbol __extension__:wrapper \
+ --symbol __leaf__:wrapper \
  --symbol __nonnull:wrapper \
  --symbol __nothrow__:wrapper \
  --symbol __pure__:wrapper \
  --symbol __REDIRECT:wrapper \
  --symbol __REDIRECT_NTH:wrapper \
- --symbol __wur:wrapper \
- -I$(top_srcdir)/libdm \
- -I$(top_srcdir)/libdm/ioctl \
- -I$(top_srcdir)/daemons/dmeventd/plugins/lvm2/ \
- $(INCLUDES) $(DEFS)
+ --symbol __restrict:type \
+ --symbol __wur:wrapper
 
 $(CFLOW_TARGET).cflow: $(CFLOW_SOURCES)
        $(CFLOW_CMD) -o$@ $(CFLOW_FLAGS) $(CFLOW_SOURCES)
index 75bb4f243dd4af2a1b263a79ccacea3b5e65c7bb..d95d956fa86c513aa534b0133f90ebc64d917b1c 100644 (file)
@@ -388,8 +388,7 @@ $(SUBDIRS.generate):
 ifneq ("$(CFLOW_LIST_TARGET)", "")
 CLEAN_CFLOW += $(CFLOW_LIST_TARGET)
 $(CFLOW_LIST_TARGET): $(CFLOW_LIST)
-       echo "CFLOW_SOURCES += $(addprefix \
-               \$$(top_srcdir)$(subst $(top_srcdir),,$(srcdir))/, $(CFLOW_LIST))" > $@
+       echo "CFLOW_SOURCES += $(addprefix $(abs_srcdir)/, $(CFLOW_LIST))" > $@
 cflow: $(CFLOW_LIST_TARGET)
 endif
 
@@ -403,21 +402,20 @@ CLEAN_CFLOW += \
 
 ifneq ("$(CFLOW_CMD)", "")
 CFLOW_FLAGS +=\
- --cpp="$(CC) -E" \
+ --cpp="$(CC) -E $(INCLUDES) $(VALGRIND_CFLAGS) $(BLKID_CFLAGS) $(DEFS)" \
  --symbol _ISbit:wrapper \
  --symbol __attribute__:wrapper \
- --symbol __const__:wrapper \
  --symbol __const:type \
- --symbol __restrict:type \
+ --symbol __const__:wrapper \
  --symbol __extension__:wrapper \
+ --symbol __leaf__:wrapper \
  --symbol __nonnull:wrapper \
  --symbol __nothrow__:wrapper \
  --symbol __pure__:wrapper \
  --symbol __REDIRECT:wrapper \
  --symbol __REDIRECT_NTH:wrapper \
- --symbol __wur:wrapper \
- -I$(top_srcdir)/daemons/dmeventd/plugins/lvm2/ \
- $(INCLUDES) $(DEFS)
+ --symbol __restrict:type \
+ --symbol __wur:wrapper
 
 $(CFLOW_TARGET).cflow: $(CFLOW_SOURCES)
        $(CFLOW_CMD) -o$@ $(CFLOW_FLAGS) $(CFLOW_SOURCES)
index a099973e11a024359621af569ee3332cebac7443..e871fbdddfb3a47a1d619256e469627ee931c225 100644 (file)
@@ -109,9 +109,9 @@ endif
 EXPORTED_HEADER = $(srcdir)/lvm2cmd.h
 EXPORTED_FN_PREFIX = lvm2
 
-CFLOW_LIST = lvmcmdlib.c lvm2cmd.c
-CFLOW_LIST_TARGET = liblvm2cmd.cflow
 CFLOW_TARGET = lvm
+CFLOW_SOURCES = $(addprefix $(srcdir)/, $(SOURCES) lvmcmdlib.c lvm2cmd.c)
+-include $(top_builddir)/lib/liblvm-internal.cflow
 
 include $(top_builddir)/make.tmpl
 
@@ -198,11 +198,7 @@ command-lines-input.h: $(srcdir)/command-lines.in Makefile
 
 $(SOURCES:%.c=%.d) $(SOURCES2:%.c=%.d): command-lines-input.h command-count.h cmds.h
 $(SOURCES:%.c=%.o) $(SOURCES2:%.c=%.o): command-lines-input.h command-count.h cmds.h
-
-ifneq ("$(CFLOW_CMD)", "")
-CFLOW_SOURCES = $(addprefix $(srcdir)/, $(SOURCES))
--include $(top_builddir)/lib/liblvm-internal.cflow
-endif
+lvm.cflow lvm.xref lvm.tree lvm.xref: command-lines-input.h command-count.h cmds.h
 
 .PHONY: install_cmdlib_dynamic install_cmdlib_static install_cmdlib_include \
        install_tools_dynamic install_tools_static
This page took 0.080732 seconds and 5 git commands to generate.