forked from Mirrors/flatpak-builder
Fix build on older glib
parent
ee2edada58
commit
b886cdb5c9
|
@ -3,12 +3,7 @@
|
|||
#include "xdg-app-utils.h"
|
||||
#include "xdg-app-dir.h"
|
||||
|
||||
#include <glib.h>
|
||||
#include <string.h>
|
||||
#include "libgsystem.h"
|
||||
#include "libglnx/libglnx.h"
|
||||
#include <libsoup/soup.h>
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
|
@ -17,6 +12,12 @@
|
|||
#include <sys/types.h>
|
||||
#include <sys/utsname.h>
|
||||
|
||||
#include <glib.h>
|
||||
#include "libgsystem.h"
|
||||
#include "libglnx/libglnx.h"
|
||||
#include <libsoup/soup.h>
|
||||
|
||||
|
||||
const char *
|
||||
xdg_app_get_arch (void)
|
||||
{
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
#ifndef __XDG_APP_UTILS_H__
|
||||
#define __XDG_APP_UTILS_H__
|
||||
|
||||
#include <string.h>
|
||||
|
||||
#include "libglnx/libglnx.h"
|
||||
#include <gio/gio.h>
|
||||
#include <libsoup/soup.h>
|
||||
#include "xdg-app-dbus.h"
|
||||
|
@ -109,4 +112,11 @@ G_DEFINE_AUTOPTR_CLEANUP_FUNC(SoupSession, g_object_unref)
|
|||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(SoupMessage, g_object_unref)
|
||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(XdgAppSessionHelper, g_object_unref)
|
||||
|
||||
#if !GLIB_CHECK_VERSION(2, 43, 4)
|
||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GFile, g_object_unref)
|
||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GFileEnumerator, g_object_unref)
|
||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GFileInfo, g_object_unref)
|
||||
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GOutputStream, g_object_unref)
|
||||
#endif
|
||||
|
||||
#endif /* __XDG_APP_UTILS_H__ */
|
||||
|
|
Loading…
Reference in New Issue