]>
Commit | Line | Data |
---|---|---|
95911c7e JB |
1 | # |
2 | # Conditional build: | |
aee54d63 | 3 | %bcond_without sysprof # sysprof profiling |
95911c7e | 4 | %bcond_without systemtap # systemtap/dtrace trace support |
68e1bbed | 5 | # |
d1e21e3e | 6 | Summary: JavaScript bindings for GNOME |
ae612451 | 7 | Summary(pl.UTF-8): Wiązania JavaScriptu dla GNOME |
d1e21e3e | 8 | Name: gjs |
9f537139 | 9 | Version: 1.64.4 |
49f7cc0a | 10 | Release: 2 |
ae612451 | 11 | License: MIT and (MPL v1.1 or GPL v2+ or LGPL v2+) |
d1e21e3e | 12 | Group: Libraries |
9b6039a6 | 13 | Source0: http://ftp.gnome.org/pub/GNOME/sources/gjs/1.64/%{name}-%{version}.tar.xz |
9f537139 | 14 | # Source0-md5: dc0d4a0453484c5a77eb0e2bda091704 |
c4adf36e | 15 | URL: https://wiki.gnome.org/Projects/Gjs |
9762e2fa MB |
16 | BuildRequires: autoconf >= 2.64 |
17 | BuildRequires: automake >= 1:1.11.1 | |
d2570104 AF |
18 | BuildRequires: cairo-devel |
19 | BuildRequires: cairo-gobject-devel | |
dee0d724 | 20 | BuildRequires: gettext-tools |
aee54d63 | 21 | BuildRequires: glib2-devel >= 1:2.58.0 |
f7239c5e | 22 | BuildRequires: gobject-introspection-devel >= 1.61.2 |
118870d4 | 23 | BuildRequires: libffi-devel |
c4adf36e | 24 | BuildRequires: libstdc++-devel >= 6:5.0 |
ee5cf52a | 25 | BuildRequires: libtool >= 2:2.2.0 |
f7239c5e | 26 | BuildRequires: meson >= 0.50.0 |
a9efafad | 27 | BuildRequires: mozjs68-devel >= 68 |
f7239c5e | 28 | BuildRequires: ninja >= 1.5 |
d1e21e3e | 29 | BuildRequires: pkgconfig |
d2570104 | 30 | BuildRequires: readline-devel |
f7239c5e | 31 | BuildRequires: rpmbuild(macros) >= 1.736 |
aee54d63 JB |
32 | # pkgconfig(sysprof-capture-3) |
33 | %{?with_sysprof:BuildRequires: sysprof-devel >= 3.34} | |
95911c7e | 34 | %{?with_systemtap:BuildRequires: systemtap-sdt-devel} |
1c06e8ee JB |
35 | BuildRequires: tar >= 1:1.22 |
36 | BuildRequires: xz | |
aee54d63 | 37 | Requires: glib2 >= 1:2.58.0 |
d1e21e3e MB |
38 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
39 | ||
40 | %description | |
41 | Gjs allows using GNOME libraries from JavaScript. It is mainly based | |
42 | on Spidermonkey JavaScript engine and the GObject introspection | |
43 | framework. | |
44 | ||
45 | %description -l pl.UTF-8 | |
ae612451 JB |
46 | Gjs pozwala używać bibliotek GNOME z JavaScriptem. Jest oparty głównie |
47 | na silniku JavaScriptu Spidermonkey i systemie GObject introspection. | |
d1e21e3e MB |
48 | |
49 | %package devel | |
50 | Summary: Header files for gjs library | |
51 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki gjs | |
52 | Group: Development/Libraries | |
53 | Requires: %{name} = %{version}-%{release} | |
ee5cf52a JB |
54 | Requires: cairo-devel |
55 | Requires: cairo-gobject-devel | |
aee54d63 | 56 | Requires: glib2-devel >= 1:2.58.0 |
f7239c5e | 57 | Requires: gobject-introspection-devel >= 1.61.2 |
ee5cf52a | 58 | Requires: libffi-devel |
49f7cc0a | 59 | Requires: mozjs68-devel >= 68 |
d1e21e3e MB |
60 | |
61 | %description devel | |
62 | Header files for gjs library. | |
63 | ||
64 | %description devel -l pl.UTF-8 | |
65 | Pliki nagłówkowe biblioteki gjs. | |
66 | ||
95911c7e JB |
67 | %package -n systemtap-gjs |
68 | Summary: systemtap/dtrace probes for gjs | |
69 | Summary(pl.UTF-8): Sondy systemtap/dtrace dla gjs | |
70 | Group: Development/Tools | |
71 | Requires: %{name} = %{version}-%{release} | |
72 | Requires: systemtap-client | |
73 | ||
74 | %description -n systemtap-gjs | |
75 | systemtap/dtrace probes for gjs. | |
76 | ||
77 | %description -n systemtap-gjs -l pl.UTF-8 | |
78 | Sondy systemtap/dtrace dla gjs. | |
79 | ||
d1e21e3e MB |
80 | %prep |
81 | %setup -q | |
82 | ||
83 | %build | |
a9efafad JR |
84 | %meson build \ |
85 | -Dprofiler=%{?with_sysprof:enabled}%{!?with_sysprof:disabled} \ | |
86 | -Dsystemtap=%{__true_false systemtap} \ | |
87 | -Ddtrace=%{__true_false systemtap} | |
88 | ||
89 | %ninja_build -C build | |
d1e21e3e MB |
90 | |
91 | %install | |
92 | rm -rf $RPM_BUILD_ROOT | |
0a8630ec | 93 | install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} |
d1e21e3e | 94 | |
a9efafad | 95 | %ninja_install -C build |
d1e21e3e | 96 | |
aee54d63 | 97 | cp -p examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} |
d1e21e3e | 98 | |
aee54d63 JB |
99 | # belongs to installed-tests |
100 | %{__rm} $RPM_BUILD_ROOT%{_datadir}/glib-2.0/schemas/org.gnome.GjsTest.gschema.xml | |
a9efafad | 101 | %{__rm} -r $RPM_BUILD_ROOT{%{_datadir},%{_libexecdir}/gjs}/installed-tests |
d1e21e3e MB |
102 | |
103 | %clean | |
104 | rm -rf $RPM_BUILD_ROOT | |
105 | ||
106 | %post -p /sbin/ldconfig | |
107 | %postun -p /sbin/ldconfig | |
108 | ||
109 | %files | |
110 | %defattr(644,root,root,755) | |
a9efafad | 111 | %doc COPYING NEWS README.md |
d1e21e3e MB |
112 | %attr(755,root,root) %{_bindir}/gjs |
113 | %attr(755,root,root) %{_bindir}/gjs-console | |
d1e21e3e MB |
114 | %attr(755,root,root) %{_libdir}/libgjs.so.*.*.* |
115 | %attr(755,root,root) %ghost %{_libdir}/libgjs.so.0 | |
1ec4cb2a ŁK |
116 | %dir %{_libdir}/gjs |
117 | %dir %{_libdir}/gjs/girepository-1.0 | |
118 | %{_libdir}/gjs/girepository-1.0/GjsPrivate-1.0.typelib | |
e8f0ae7c | 119 | %{_datadir}/gjs-1.0 |
d1e21e3e MB |
120 | |
121 | %files devel | |
122 | %defattr(644,root,root,755) | |
d1e21e3e | 123 | %attr(755,root,root) %{_libdir}/libgjs.so |
d1e21e3e MB |
124 | %{_includedir}/gjs-1.0 |
125 | %{_pkgconfigdir}/gjs-1.0.pc | |
d1e21e3e | 126 | %{_examplesdir}/%{name}-%{version} |
95911c7e | 127 | |
ab1adb5b | 128 | %if %{with systemtap} |
95911c7e JB |
129 | %files -n systemtap-gjs |
130 | %defattr(644,root,root,755) | |
131 | %{_datadir}/systemtap/tapset/gjs.stp | |
ab1adb5b | 132 | %endif |