]> git.pld-linux.org Git - packages/cjs.git/blame - cjs.spec
Release 2 (by relup.sh)
[packages/cjs.git] / cjs.spec
CommitLineData
9f107e75
ER
1#
2# Conditional build:
f38c6e9e 3%bcond_without sysprof # sysprof profiling support
9793fb5c
JB
4%bcond_without systemtap # systemtap/dtrace trace support
5%bcond_with tests # JS tests (upstream failed to update them, e.g. tests for version < 4.0.0; some require $DISPLAY)
9f107e75
ER
6
7Summary: Javascript Bindings for Cinnamon
9793fb5c 8Summary(pl.UTF-8): Wiązania JavaScriptu dla środowiska Cinnamon
9f107e75 9Name: cjs
5d0b4be1 10Version: 4.8.2
412e28ef 11Release: 2
9f107e75
ER
12Group: Libraries
13# The following files contain code from Mozilla which
14# is triple licensed under MPL1.1/LGPLv2+/GPLv2+:
15# The console module (modules/console.c)
16# Stack printer (gjs/stack.c)
9793fb5c
JB
17License: MIT and (MPL v1.1 or GPL v2+ or LGPL v2+)
18#Source0Download: https://github.com/linuxmint/cjs/releases
9f107e75 19Source0: https://github.com/linuxmint/cjs/archive/%{version}/%{name}-%{version}.tar.gz
5d0b4be1 20# Source0-md5: b9444c6e537ebb3838518a16054804ff
9793fb5c 21URL: https://github.com/linuxmint/Cinnamon
9f107e75 22BuildRequires: cairo-gobject-devel
5d0b4be1
JB
23BuildRequires: glib2-devel >= 1:2.58.0
24BuildRequires: gobject-introspection-devel >= 1.58.3
25BuildRequires: gtk4-devel >= 4.0
9793fb5c 26BuildRequires: libffi-devel >= 3.0
5d0b4be1
JB
27BuildRequires: libstdc++-devel >= 6:7
28BuildRequires: meson >= 0.49.2
29BuildRequires: mozjs78-devel >= 78
30BuildRequires: ninja >= 1.5
9793fb5c 31BuildRequires: pkgconfig >= 1:0.14.0
9f107e75 32BuildRequires: readline-devel
5d0b4be1
JB
33BuildRequires: rpmbuild(macros) >= 1.736
34BuildRequires: sed >= 4.0
35%{?with_sysprof:BuildRequires: sysprof-devel >= 3.38}
9793fb5c 36%{?with_systemtap:BuildRequires: systemtap-sdt-devel}
5d0b4be1
JB
37Requires: glib2 >= 1:2.58.0
38Requires: gobject-introspection >= 1.58.3
9f107e75
ER
39BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
40
41%description
5d0b4be1
JB
42Cjs allows using Cinnamon libraries from JavaScript. It's based on the
43SpiderMonkey JavaScript engine from Mozilla and the GObject
9f107e75
ER
44introspection framework.
45
5d0b4be1
JB
46%description -l pl.UTF-8
47Cjs pozwala na używanie bibliotek Cinnamona z poziomu JavaScriptu.
48Jest oparty na silniku JavaScriptu SpiderMonkey z projektu Mozilla
49oraz szkielecie GObject Introspection.
50
9f107e75 51%package devel
9793fb5c
JB
52Summary: Development package for cjs
53Summary(pl.UTF-8): Pakiet programistyczny cjs
9f107e75
ER
54Group: Development/Libraries
55Requires: %{name} = %{version}-%{release}
9793fb5c 56Requires: cairo-gobject-devel
5d0b4be1
JB
57Requires: glib2-devel >= 1:2.58.0
58Requires: gobject-introspection-devel >= 1.58.3
9793fb5c 59Requires: libffi-devel >= 3.0
5d0b4be1 60Requires: mozjs78-devel >= 78
9f107e75
ER
61
62%description devel
9793fb5c
JB
63Files for development with cjs.
64
65%description devel -l pl.UTF-8
66Pliki do tworzenia oprogramowania z użyciem cjs
9f107e75
ER
67
68%package tests
69Summary: Tests for the cjs package
9793fb5c 70Summary(pl.UTF-8): Testy dla pakietu cjs
9f107e75 71Group: Development/Libraries
5d0b4be1 72Requires(post,postun): glib2-devel >= 1:2.58.0
9f107e75
ER
73Requires: %{name}-devel = %{version}-%{release}
74
75%description tests
76The cjs-tests package contains tests that can be used to verify the
77functionality of the installed cjs package.
78
9793fb5c
JB
79%description tests -l pl.UTF-8
80Ten pakiet zawiera testy, których można użyć do sprawdzenia
81funkcjonalności zainstalowanego pakietu cjs.
82
83%package -n systemtap-cjs
84Summary: systemtap/dtrace probes for cjs
85Summary(pl.UTF-8): Sondy systemtap/dtrace dla cjs
86Group: Development/Tools
87Requires: %{name} = %{version}-%{release}
88Requires: systemtap-client
89
90%description -n systemtap-cjs
91systemtap/dtrace probes for cjs.
92
93%description -n systemtap-cjs -l pl.UTF-8
94Sondy systemtap/dtrace dla cjs.
95
9f107e75
ER
96%prep
97%setup -q
9f107e75 98
5d0b4be1
JB
99%{__sed} -i -e 's/ library(/ shared_library(/' installed-tests/js/meson.build
100
9f107e75 101%build
5d0b4be1
JB
102%meson build \
103 %{?with_systemtap:-Ddtrace=true} \
104 %{!?with_sysprof:-Dprofiler=disabled} \
105 %{?with_systemtap:-Dsystemtap=true}
106
107%ninja_build -C build
9f107e75
ER
108
109%if %{with tests}
5d0b4be1 110%ninja_test -C build
9f107e75
ER
111%endif
112
113%install
114rm -rf $RPM_BUILD_ROOT
9793fb5c 115
5d0b4be1 116%ninja_install -C build
9f107e75 117
9793fb5c
JB
118install -d $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
119cp -p examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
120
9f107e75
ER
121%clean
122rm -rf $RPM_BUILD_ROOT
123
124%post -p /sbin/ldconfig
125%postun -p /sbin/ldconfig
126
5d0b4be1
JB
127%post tests
128%glib_compile_schemas
129
130%postun tests
131%glib_compile_schemas
132
9f107e75
ER
133%files
134%defattr(644,root,root,755)
188d188f 135%doc COPYING NEWS README.md debian/changelog
9f107e75
ER
136%attr(755,root,root) %{_bindir}/cjs
137%attr(755,root,root) %{_bindir}/cjs-console
138%attr(755,root,root) %{_libdir}/libcjs.so.*.*.*
139%ghost %{_libdir}/libcjs.so.0
140%dir %{_libdir}/cjs
141%dir %{_libdir}/cjs/girepository-1.0
142%{_libdir}/cjs/girepository-1.0/CjsPrivate-1.0.typelib
5d0b4be1 143%{_datadir}/cjs-1.0
9f107e75
ER
144
145%files devel
146%defattr(644,root,root,755)
9793fb5c 147%attr(755,root,root) %{_libdir}/libcjs.so
9f107e75 148%{_includedir}/cjs-1.0
9f107e75 149%{_pkgconfigdir}/cjs-1.0.pc
9793fb5c 150%{_examplesdir}/%{name}-%{version}
9f107e75
ER
151
152%files tests
153%defattr(644,root,root,755)
5d0b4be1
JB
154# TODO: move system-side installed-tests dirs somewhere (filesystem?)
155%dir %{_libexecdir}/installed-tests
156%dir %{_libexecdir}/installed-tests/cjs
157%attr(755,root,root) %{_libexecdir}/installed-tests/cjs/debugger-test.sh
158%attr(755,root,root) %{_libexecdir}/installed-tests/cjs/minijasmine
159%attr(755,root,root) %{_libexecdir}/installed-tests/cjs/lib*.so
160%{_libexecdir}/installed-tests/cjs/*.typelib
161%{_libexecdir}/installed-tests/cjs/debugger
162%{_libexecdir}/installed-tests/cjs/js
163%dir %{_libexecdir}/installed-tests/cjs/scripts
164%attr(755,root,root) %{_libexecdir}/installed-tests/cjs/scripts/test*.sh
165%{_datadir}/glib-2.0/schemas/org.cinnamon.CjsTest.gschema.xml
9793fb5c
JB
166%dir %{_datadir}/installed-tests
167%{_datadir}/installed-tests/cjs
168
169%if %{with systemtap}
170%files -n systemtap-cjs
171%defattr(644,root,root,755)
172%{_datadir}/systemtap/tapset/cjs.stp
173%endif
This page took 0.288943 seconds and 4 git commands to generate.