summaryrefslogtreecommitdiff
path: root/src/qmi-firmware-update/qfu-udev-helpers.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/qmi-firmware-update/qfu-udev-helpers.h')
-rw-r--r--src/qmi-firmware-update/qfu-udev-helpers.h22
1 files changed, 14 insertions, 8 deletions
diff --git a/src/qmi-firmware-update/qfu-udev-helpers.h b/src/qmi-firmware-update/qfu-udev-helpers.h
index b12b8df..6f6eac0 100644
--- a/src/qmi-firmware-update/qfu-udev-helpers.h
+++ b/src/qmi-firmware-update/qfu-udev-helpers.h
@@ -22,10 +22,22 @@
#ifndef QFU_UDEV_HELPERS_H
#define QFU_UDEV_HELPERS_H
+#include "config.h"
+
#include <gio/gio.h>
G_BEGIN_DECLS
+typedef enum {
+ QFU_UDEV_HELPER_DEVICE_TYPE_TTY,
+ QFU_UDEV_HELPER_DEVICE_TYPE_CDC_WDM,
+ QFU_UDEV_HELPER_DEVICE_TYPE_LAST
+} QfuUdevHelperDeviceType;
+
+const gchar *qfu_udev_helper_device_type_to_string (QfuUdevHelperDeviceType type);
+
+#if defined WITH_UDEV
+
gchar *qfu_udev_helper_find_by_file (GFile *file,
GError **error);
gchar *qfu_udev_helper_find_by_file_path (const gchar *path,
@@ -36,14 +48,6 @@ gchar *qfu_udev_helper_find_by_device_info (guint16 vid,
guint devnum,
GError **error);
-typedef enum {
- QFU_UDEV_HELPER_DEVICE_TYPE_TTY,
- QFU_UDEV_HELPER_DEVICE_TYPE_CDC_WDM,
- QFU_UDEV_HELPER_DEVICE_TYPE_LAST
-} QfuUdevHelperDeviceType;
-
-const gchar *qfu_udev_helper_device_type_to_string (QfuUdevHelperDeviceType type);
-
GList *qfu_udev_helper_list_devices (QfuUdevHelperDeviceType device_type,
const gchar *sysfs_path);
@@ -59,6 +63,8 @@ typedef struct _QfuUdevHelperGenericMonitor QfuUdevHelperGenericMonitor;
QfuUdevHelperGenericMonitor *qfu_udev_helper_generic_monitor_new (const gchar *sysfs_path);
void qfu_udev_helper_generic_monitor_free (QfuUdevHelperGenericMonitor *self);
+#endif
+
G_END_DECLS
#endif /* QFU_UDEV_HELPERS_H */