From: Philippe Proulx Date: Wed, 24 Feb 2016 08:52:08 +0000 (-0500) Subject: Plugins: rename reader -> fs, and symbols.c to plugin.c X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=6a29d9fdf573e71039efd407da89e36f8c11ee42;p=deliverable%2Fbabeltrace.git Plugins: rename reader -> fs, and symbols.c to plugin.c Signed-off-by: Jérémie Galarneau --- diff --git a/configure.ac b/configure.ac index c4045cd77..9e36c48e4 100644 --- a/configure.ac +++ b/configure.ac @@ -372,7 +372,7 @@ AC_CONFIG_FILES([ extras/valgrind/Makefile plugins/Makefile plugins/ctf/Makefile - plugins/ctf/reader/Makefile + plugins/ctf/fs/Makefile plugins/ctf/lttng-live/Makefile plugins/text/Makefile babeltrace.pc diff --git a/plugins/ctf/Makefile.am b/plugins/ctf/Makefile.am index 5ad99a365..46fe3ec49 100644 --- a/plugins/ctf/Makefile.am +++ b/plugins/ctf/Makefile.am @@ -1,11 +1,11 @@ AM_CFLAGS = $(PACKAGE_CFLAGS) -I$(top_srcdir)/include -SUBDIRS = reader lttng-live +SUBDIRS = fs lttng-live lib_LTLIBRARIES = libbabeltrace-plugin-ctf.la # ctf plugin -libbabeltrace_plugin_ctf_la_SOURCES = symbols.c +libbabeltrace_plugin_ctf_la_SOURCES = plugin.c libbabeltrace_plugin_ctf_la_LDFLAGS = \ -version-info $(BABELTRACE_LIBRARY_VERSION) @@ -13,5 +13,5 @@ libbabeltrace_plugin_ctf_la_LDFLAGS = \ libbabeltrace_plugin_ctf_la_LIBADD = \ $(top_builddir)/lib/libbabeltrace.la \ $(top_builddir)/formats/ctf/libbabeltrace-ctf.la \ - $(top_builddir)/plugins/ctf/reader/libbabeltrace-plugin-ctf-reader.la \ + $(top_builddir)/plugins/ctf/fs/libbabeltrace-plugin-ctf-fs.la \ $(top_builddir)/plugins/ctf/lttng-live/libbabeltrace-plugin-ctf-lttng-live.la diff --git a/plugins/ctf/fs/Makefile.am b/plugins/ctf/fs/Makefile.am new file mode 100644 index 000000000..c36bd43db --- /dev/null +++ b/plugins/ctf/fs/Makefile.am @@ -0,0 +1,8 @@ +AM_CFLAGS = $(PACKAGE_CFLAGS) -I$(top_srcdir)/include + +noinst_HEADERS = fs-internal.h +noinst_LTLIBRARIES = libbabeltrace-plugin-ctf-fs.la + +# Plug-in system library +libbabeltrace_plugin_ctf_fs_la_SOURCES = \ + fs.c diff --git a/plugins/ctf/fs/fs-internal.h b/plugins/ctf/fs/fs-internal.h new file mode 100644 index 000000000..3f87bd0ea --- /dev/null +++ b/plugins/ctf/fs/fs-internal.h @@ -0,0 +1,41 @@ +#ifndef BABELTRACE_PLUGIN_CTF_FS_INTERNAL_H +#define BABELTRACE_PLUGIN_CTF_FS_INTERNAL_H + +/* + * BabelTrace - CTF on File System Component + * + * Copyright 2016 Jérémie Galarneau + * + * Author: Jérémie Galarneau + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +#include +#include + +#define FS_COMPONENT_NAME "ctf" +#define FS_COMPONENT_DESCRIPTION \ + "Component used to read a CTF trace located on a file system." + +BT_HIDDEN +enum bt_component_status fs_init(struct bt_component *source, + struct bt_value *params); + +#endif /* BABELTRACE_PLUGIN_CTF_FS_INTERNAL_H */ diff --git a/plugins/ctf/fs/fs.c b/plugins/ctf/fs/fs.c new file mode 100644 index 000000000..1142691ed --- /dev/null +++ b/plugins/ctf/fs/fs.c @@ -0,0 +1,39 @@ +/* + * reader.c + * + * Babeltrace CTF Reader Component + * + * Copyright 2016 Jérémie Galarneau + * + * Author: Jérémie Galarneau + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +#include "fs-internal.h" +#include + +BT_HIDDEN +enum bt_component_status fs_init(struct bt_component *component, + struct bt_value *params) +{ + return BT_COMPONENT_STATUS_OK; +} + + diff --git a/plugins/ctf/plugin.c b/plugins/ctf/plugin.c new file mode 100644 index 000000000..16c2c5b6e --- /dev/null +++ b/plugins/ctf/plugin.c @@ -0,0 +1,45 @@ +/* + * symbols.c + * + * Babeltrace CTF Plug-in Registration Symbols + * + * Copyright 2016 Jérémie Galarneau + * + * Author: Jérémie Galarneau + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + * SOFTWARE. + */ + +#include +#include "fs/fs-internal.h" +#include "lttng-live/lttng-live-internal.h" + +/* Initialize plug-in entry points. */ +BT_PLUGIN_NAME("ctf"); +BT_PLUGIN_DESCRIPTION("Babeltrace CTF plug-in."); +BT_PLUGIN_AUTHOR("Jérémie Galarneau"); +BT_PLUGIN_LICENSE("MIT"); + +BT_PLUGIN_COMPONENT_CLASSES_BEGIN +BT_PLUGIN_SOURCE_COMPONENT_CLASS_ENTRY(FS_COMPONENT_NAME, + FS_COMPONENT_DESCRIPTION, fs_init); +BT_PLUGIN_SOURCE_COMPONENT_CLASS_ENTRY(LTTNG_LIVE_COMPONENT_NAME, + LTTNG_LIVE_COMPONENT_DESCRIPTION, lttng_live_init); +BT_PLUGIN_COMPONENT_CLASSES_END + diff --git a/plugins/ctf/reader/Makefile.am b/plugins/ctf/reader/Makefile.am deleted file mode 100644 index 4233d4aee..000000000 --- a/plugins/ctf/reader/Makefile.am +++ /dev/null @@ -1,8 +0,0 @@ -AM_CFLAGS = $(PACKAGE_CFLAGS) -I$(top_srcdir)/include - -noinst_HEADERS = reader-internal.h -noinst_LTLIBRARIES = libbabeltrace-plugin-ctf-reader.la - -# Plug-in system library -libbabeltrace_plugin_ctf_reader_la_SOURCES = \ - reader.c diff --git a/plugins/ctf/reader/reader-internal.h b/plugins/ctf/reader/reader-internal.h deleted file mode 100644 index 1ebae6046..000000000 --- a/plugins/ctf/reader/reader-internal.h +++ /dev/null @@ -1,40 +0,0 @@ -#ifndef BABELTRACE_PLUGIN_CTF_READER_INTERNAL_H -#define BABELTRACE_PLUGIN_CTF_READER_INTERNAL_H - -/* - * BabelTrace - CTF Reader Component - * - * Copyright 2016 Jérémie Galarneau - * - * Author: Jérémie Galarneau - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ - -#include -#include - -#define READER_COMPONENT_NAME "ctf" -#define READER_COMPONENT_DESCRIPTION "Component used to read on-disk CTF traces." - -BT_HIDDEN -enum bt_component_status ctf_init(struct bt_component *source, - struct bt_value *params); - -#endif /* BABELTRACE_PLUGIN_CTF_READER_INTERNAL_H */ diff --git a/plugins/ctf/reader/reader.c b/plugins/ctf/reader/reader.c deleted file mode 100644 index ccf860abd..000000000 --- a/plugins/ctf/reader/reader.c +++ /dev/null @@ -1,39 +0,0 @@ -/* - * reader.c - * - * Babeltrace CTF Reader Component - * - * Copyright 2016 Jérémie Galarneau - * - * Author: Jérémie Galarneau - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ - -#include "reader-internal.h" -#include - -BT_HIDDEN -enum bt_component_status ctf_init(struct bt_component *component, - struct bt_value *params) -{ - return BT_COMPONENT_STATUS_OK; -} - - diff --git a/plugins/ctf/symbols.c b/plugins/ctf/symbols.c deleted file mode 100644 index 2cc423ea5..000000000 --- a/plugins/ctf/symbols.c +++ /dev/null @@ -1,45 +0,0 @@ -/* - * symbols.c - * - * Babeltrace CTF Plug-in Registration Symbols - * - * Copyright 2016 Jérémie Galarneau - * - * Author: Jérémie Galarneau - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ - -#include -#include "reader/reader-internal.h" -#include "lttng-live/lttng-live-internal.h" - -/* Initialize plug-in entry points. */ -BT_PLUGIN_NAME("ctf"); -BT_PLUGIN_DESCRIPTION("Babeltrace CTF plug-in."); -BT_PLUGIN_AUTHOR("Jérémie Galarneau"); -BT_PLUGIN_LICENSE("MIT"); - -BT_PLUGIN_COMPONENT_CLASSES_BEGIN -BT_PLUGIN_SOURCE_COMPONENT_CLASS_ENTRY(READER_COMPONENT_NAME, - READER_COMPONENT_DESCRIPTION, ctf_init); -BT_PLUGIN_SOURCE_COMPONENT_CLASS_ENTRY(LTTNG_LIVE_COMPONENT_NAME, - LTTNG_LIVE_COMPONENT_DESCRIPTION, lttng_live_init); -BT_PLUGIN_COMPONENT_CLASSES_END -