]> sigrok.org Git - libsigrok.git/commitdiff
configure: Add --enable-demo option.
authorUwe Hermann <redacted>
Tue, 11 Jan 2011 21:17:33 +0000 (22:17 +0100)
committerUwe Hermann <redacted>
Tue, 11 Jan 2011 21:17:33 +0000 (22:17 +0100)
hardware/Makefile.am
hardware/demo/Makefile.am
hwplugin.c

index 3b805e1e8a58ed897a4038c6a96982afab4c7a93..eb7088f39d071359e25aab55494d274fdef67dbe 100644 (file)
@@ -31,8 +31,11 @@ noinst_LTLIBRARIES = libsigrokhardware.la
 libsigrokhardware_la_SOURCES =
 
 libsigrokhardware_la_LIBADD = \
-       common/libsigrokhwcommon.la \
-       demo/libsigrokhwdemo.la
+       common/libsigrokhwcommon.la
+
+if LA_DEMO
+libsigrokhardware_la_LIBADD += demo/libsigrokhwdemo.la
+endif
 
 if LA_ASIX_SIGMA
 libsigrokhardware_la_LIBADD += asix-sigma/libsigrokhwasixsigma.la
index 28287baf4d182e35992f71ea816906d3c162df9f..025c1648c3d50c234ec6cc96e66561b452b1157f 100644 (file)
@@ -17,6 +17,8 @@
 ## along with this program.  If not, see <http://www.gnu.org/licenses/>.
 ##
 
+if LA_DEMO
+
 # Local lib, this is NOT meant to be installed!
 noinst_LTLIBRARIES = libsigrokhwdemo.la
 
@@ -26,3 +28,5 @@ libsigrokhwdemo_la_SOURCES = \
 libsigrokhwdemo_la_CFLAGS = \
        -I$(top_srcdir)/libsigrok
 
+endif
+
index c5a0b2e9852aa2cedb08b3981c3ed182e97cc62f..c248476bd1d4321e054641736175c39a3edaf4ca 100644 (file)
@@ -42,7 +42,9 @@ struct hwcap_option hwcap_options[] = {
        {0, 0, NULL, NULL},
 };
 
+#ifdef HAVE_LA_DEMO
 extern struct device_plugin demo_plugin_info;
+#endif
 #ifdef HAVE_LA_SALEAE_LOGIC
 extern struct device_plugin saleae_logic_plugin_info;
 #endif
@@ -63,7 +65,9 @@ extern struct device_plugin link_mso19_plugin_info;
 /* TODO: No linked list needed, this can be a simple array. */
 int load_hwplugins(void)
 {
+#ifdef HAVE_LA_DEMO
        plugins = g_slist_append(plugins, (gpointer *)&demo_plugin_info);
+#endif
 #ifdef HAVE_LA_SALEAE_LOGIC
        plugins =
            g_slist_append(plugins, (gpointer *)&saleae_logic_plugin_info);