4 Summary: Library for JavaScript Object Notation format
6 Group: Development/Libraries/C and C++
7 Url: https://wiki.gnome.org/Projects/JsonGlib
8 Source0: https://download.gnome.org/sources/json-glib/1.6/%{name}-%{version}.tar.xz
9 Source99: baselibs.conf
10 Source1001: json-glib.manifest
11 Source1002: apply_PIE_option.patch
12 BuildRequires: gettext
13 BuildRequires: gobject-introspection-devel
14 BuildRequires: pkgconfig(glib-2.0)
18 JSON-GLib provides a parser and a generator GObject classes and various
19 wrappers for the complex data types employed by JSON, such as arrays
22 JSON-GLib uses GLib native data types and the generic value container
23 GValue for ease of development. It also provides integration with the
24 GObject classes for direct serialization into, and deserialization from,
27 %package -n libjson-glib
28 Summary: Library for JavaScript Object Notation format
29 # To make lang subpackage installable
30 Group: Development/Libraries/C and C++
31 Recommends: %{name}-lang
32 Provides: %{name} = %{version}
34 %description -n libjson-glib
35 JSON is a lightweight data-interchange format. It is comparatively
36 easy for humans to read and write, and for machines to parse and generate.
38 JSON-GLib provides a parser and a generator GObject classes and various
39 wrappers for the complex data types employed by JSON, such as arrays
42 JSON-GLib uses GLib native data types and the generic value container
43 GValue for ease of development. It also provides integration with the
44 GObject classes for direct serialization into, and deserialization from,
47 %package -n typelib-Json
48 Summary: Introspection bindings for libjson-glib
49 Group: System/Libraries
51 %description -n typelib-Json
52 JSON-GLib provides a parser and a generator GObject classes and various
53 wrappers for the complex data types employed by JSON, such as arrays
56 This package provides the GObject Introspection bindings for JSON-GLib.
59 Summary: Development files for libjson-glib
60 Group: Development/Libraries/C and C++
61 Requires: libjson-glib = %{version}
62 Requires: typelib-Json = %{version}
63 #BuildRequires: gettext
64 #BuildRequires: gtk-doc
67 JSON-GLib provides a parser and a generator GObject classes and various
68 wrappers for the complex data types employed by JSON, such as arrays
71 This package contains development files needed to develop with the
79 %{__patch} -p1 < %{SOURCE1002}
82 export CFLAGS+=" -fPIC"
85 meson --prefix /usr --libdir %{_libdir} builddir
89 ninja -C builddir meson-test || exit 0
92 DESTDIR=%{buildroot} ninja -C builddir install
93 find %{buildroot}%{_libdir} -name '*.la' -delete -print
94 %find_lang %{name}-1.0
96 mv %{name}-1.0.lang %{name}.lang
97 %__rm -rf %{buildroot}%{_datadir}/gtk-doc
99 %post -n libjson-glib -p /sbin/ldconfig
101 %postun -n libjson-glib -p /sbin/ldconfig
103 %files -n libjson-glib
104 %manifest %{name}.manifest
105 %defattr(-,root,root)
106 %{_bindir}/json-glib-format
107 %{_bindir}/json-glib-validate
111 %files -n typelib-Json
112 %manifest %{name}.manifest
113 %defattr(-,root,root)
114 %{_libdir}/girepository-1.0/Json-1.0.typelib
117 %manifest %{name}.manifest
118 %defattr(-,root,root)
119 %{_includedir}/%{name}-1.0
121 %{_libdir}/pkgconfig/*.pc
122 %{_datadir}/gir-1.0/*.gir
123 %dir %{_datadir}/installed-tests
124 %dir %{_libexecdir}/installed-tests
125 %{_datadir}/installed-tests/json-glib-1.0/
126 %{_libexecdir}/installed-tests/json-glib-1.0/
128 #%files lang -f %{name}-1.0.lang