[ostree] Add libgsystem as git external
- From: Colin Walters <walters src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [ostree] Add libgsystem as git external
- Date: Sun, 15 Jul 2012 16:00:23 +0000 (UTC)
commit 464f4a81c9bd0b7e43fb299e3a64cde9a2e1be60
Author: Colin Walters <walters verbum org>
Date: Sun Jul 15 11:51:57 2012 -0400
Add libgsystem as git external
Don't replace ot_lfree and stuff yet though...to much code churn.
.gitmodules | 3 ++
Makefile-daemon.am | 2 +-
Makefile-libostree.am | 2 +-
Makefile-ostadmin.am | 4 +-
Makefile-ostree.am | 2 +-
Makefile-otutil.am | 5 +--
Makefile.am | 4 ++
src/libgsystem | 1 +
src/libotutil/ot-local-alloc.c | 72 ----------------------------------------
src/libotutil/ot-local-alloc.h | 17 +++------
10 files changed, 21 insertions(+), 91 deletions(-)
---
diff --git a/.gitmodules b/.gitmodules
new file mode 100644
index 0000000..f456a14
--- /dev/null
+++ b/.gitmodules
@@ -0,0 +1,3 @@
+[submodule "src/libgsystem"]
+ path = src/libgsystem
+ url = git://git.gnome.org/libgsystem
diff --git a/Makefile-daemon.am b/Makefile-daemon.am
index caa97f2..aab7e40 100644
--- a/Makefile-daemon.am
+++ b/Makefile-daemon.am
@@ -24,5 +24,5 @@ ostreed_SOURCES = src/daemon/ostreed.c \
src/daemon/ot-daemon.c \
$(NULL)
-ostreed_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/src/libotutil -I$(srcdir)/src/libostree -I$(srcdir)/src/daemon -DLOCALEDIR=\"$(datadir)/locale\" $(OT_INTERNAL_GIO_UNIX_CFLAGS)
+ostreed_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/src/libgsystem -I$(srcdir)/src/libotutil -I$(srcdir)/src/libostree -I$(srcdir)/src/daemon -DLOCALEDIR=\"$(datadir)/locale\" $(OT_INTERNAL_GIO_UNIX_CFLAGS)
ostreed_LDADD = libotutil.la libostree.la $(OT_INTERNAL_GIO_UNIX_LIBS)
diff --git a/Makefile-libostree.am b/Makefile-libostree.am
index 2d2b3b2..89e7b19 100644
--- a/Makefile-libostree.am
+++ b/Makefile-libostree.am
@@ -46,7 +46,7 @@ libostree_la_SOURCES += src/libostree/ostree-libarchive-input-stream.h \
$(NULL)
endif
-libostree_la_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/src/libotutil -I$(srcdir)/src/libostree -DLOCALEDIR=\"$(datadir)/locale\" $(OT_INTERNAL_GIO_UNIX_CFLAGS)
+libostree_la_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/src/libgsystem -I$(srcdir)/src/libotutil -I$(srcdir)/src/libostree -DLOCALEDIR=\"$(datadir)/locale\" $(OT_INTERNAL_GIO_UNIX_CFLAGS)
libostree_la_LDFLAGS = -avoid-version -Bsymbolic-functions
libostree_la_LIBADD = libotutil.la $(OT_INTERNAL_GIO_UNIX_LIBS)
diff --git a/Makefile-ostadmin.am b/Makefile-ostadmin.am
index f0e0112..16eca42 100644
--- a/Makefile-ostadmin.am
+++ b/Makefile-ostadmin.am
@@ -25,5 +25,5 @@ ostadmin_SOURCES = src/ostadmin/main.c \
src/ostadmin/ot-admin-main.c \
$(NULL)
-ostadmin_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/src/libotutil -I$(srcdir)/src/libostree -I$(srcdir)/src/ostadmin -DLOCALEDIR=\"$(datadir)/locale\" $(OT_INTERNAL_GIO_UNIX_CFLAGS)
-ostadmin_LDADD = libotutil.la libostree.la $(OT_INTERNAL_GIO_UNIX_LIBS)
+ostadmin_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/src/libgsystem -I$(srcdir)/src/libotutil -I$(srcdir)/src/libostree -I$(srcdir)/src/ostadmin -DLOCALEDIR=\"$(datadir)/locale\" $(OT_INTERNAL_GIO_UNIX_CFLAGS)
+ostadmin_LDADD = libgsystem.la libotutil.la libostree.la $(OT_INTERNAL_GIO_UNIX_LIBS)
diff --git a/Makefile-ostree.am b/Makefile-ostree.am
index b5b07b4..9571e5e 100644
--- a/Makefile-ostree.am
+++ b/Makefile-ostree.am
@@ -43,7 +43,7 @@ ostree_SOURCES = src/ostree/main.c \
src/ostree/ot-main.c \
$(NULL)
-ostree_bin_shared_cflags = $(AM_CFLAGS) -I$(srcdir)/src/libotutil -I$(srcdir)/src/libostree -I$(srcdir)/src/ostree -DLOCALEDIR=\"$(datadir)/locale\"
+ostree_bin_shared_cflags = $(AM_CFLAGS) -I$(srcdir)/src/libgsystem -I$(srcdir)/src/libotutil -I$(srcdir)/src/libostree -I$(srcdir)/src/ostree -DLOCALEDIR=\"$(datadir)/locale\"
ostree_bin_shared_ldadd = libotutil.la libostree.la
ostree_CFLAGS = $(ostree_bin_shared_cflags) $(OT_INTERNAL_GIO_UNIX_CFLAGS)
diff --git a/Makefile-otutil.am b/Makefile-otutil.am
index cf7c50e..5d88716 100644
--- a/Makefile-otutil.am
+++ b/Makefile-otutil.am
@@ -22,7 +22,6 @@ noinst_LTLIBRARIES += libotutil.la
libotutil_la_SOURCES = \
src/libotutil/ot-checksum-utils.c \
src/libotutil/ot-checksum-utils.h \
- src/libotutil/ot-local-alloc.c \
src/libotutil/ot-local-alloc.h \
src/libotutil/ot-opt-utils.c \
src/libotutil/ot-opt-utils.h \
@@ -39,5 +38,5 @@ libotutil_la_SOURCES = \
src/libotutil/otutil.c \
src/libotutil/otutil.h \
$(NULL)
-libotutil_la_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/src/libotutil -DLOCALEDIR=\"$(datadir)/locale\" $(OT_INTERNAL_GIO_UNIX_CFLAGS)
-libotutil_la_LIBADD = $(OT_INTERNAL_GIO_UNIX_LIBS)
+libotutil_la_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/src/libgsystem -I$(srcdir)/src/libotutil -DLOCALEDIR=\"$(datadir)/locale\" $(OT_INTERNAL_GIO_UNIX_CFLAGS)
+libotutil_la_LIBADD = $(OT_INTERNAL_GIO_UNIX_LIBS) libgsystem.la
diff --git a/Makefile.am b/Makefile.am
index ad85e97..101dec6 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -68,6 +68,10 @@ OT_INTERNAL_SOUP_CFLAGS = $(OT_DEP_SOUP_CFLAGS)
OT_INTERNAL_SOUP_LIBS = $(OT_DEP_SOUP_LIBS)
endif
+libgsystem_srcpath := src/libgsystem
+libgsystem_cflags = $(OT_INTERNAL_GIO_UNIX_CFLAGS)
+libgsystem_libs = $(OT_INTERNAL_GIO_UNIX_LIBS)
+include src/libgsystem/Makefile-libgsystem.am
include Makefile-daemon.am
include Makefile-otutil.am
include Makefile-libostree.am
diff --git a/src/libgsystem b/src/libgsystem
new file mode 160000
index 0000000..ba5d748
--- /dev/null
+++ b/src/libgsystem
@@ -0,0 +1 @@
+Subproject commit ba5d74802c0ffe51bd18d2ba64db87e1e7456349
diff --git a/src/libotutil/ot-local-alloc.h b/src/libotutil/ot-local-alloc.h
index 3cbfc52..ee3b93f 100644
--- a/src/libotutil/ot-local-alloc.h
+++ b/src/libotutil/ot-local-alloc.h
@@ -24,20 +24,15 @@
#define __OSTREE_LOCAL_ALLOC_H__
#include <gio/gio.h>
+#include "libgsystem.h"
G_BEGIN_DECLS
-void ot_local_free (void *loc);
-void ot_local_obj_unref (void *loc);
-void ot_local_variant_unref (GVariant **loc);
-void ot_local_ptrarray_unref (GPtrArray **loc);
-void ot_local_hashtable_unref (GHashTable **loc);
-
-#define ot_lfree __attribute__ ((cleanup(ot_local_free)))
-#define ot_lobj __attribute__ ((cleanup(ot_local_obj_unref)))
-#define ot_lvariant __attribute__ ((cleanup(ot_local_variant_unref)))
-#define ot_lptrarray __attribute__ ((cleanup(ot_local_ptrarray_unref)))
-#define ot_lhash __attribute__ ((cleanup(ot_local_hashtable_unref)))
+#define ot_lfree __attribute__ ((cleanup(gs_local_free)))
+#define ot_lobj __attribute__ ((cleanup(gs_local_obj_unref)))
+#define ot_lvariant __attribute__ ((cleanup(gs_local_variant_unref)))
+#define ot_lptrarray __attribute__ ((cleanup(gs_local_ptrarray_unref)))
+#define ot_lhash __attribute__ ((cleanup(gs_local_hashtable_unref)))
G_END_DECLS
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]