1 |
brianr |
1.1 |
%define name smeserver-manager-jsquery |
2 |
|
|
%define version 1.0 |
3 |
brianr |
1.2 |
%define release 2 |
4 |
brianr |
1.1 |
Summary: Jsquery and associated plugins plus server-manager (2) specific overrides. |
5 |
|
|
Name: %{name} |
6 |
|
|
Version: %{version} |
7 |
|
|
Release: %{release}%{?dist} |
8 |
|
|
Source: %{name}-%{version}.tar.gz |
9 |
|
|
License: GNU GPL version 2 |
10 |
|
|
Group: SMEserver/addon |
11 |
brianr |
1.2 |
Patch0: smeserver-manager-jsquery-1.0-Fix-css-override-for-dataTables.patch |
12 |
|
|
|
13 |
brianr |
1.1 |
BuildRoot: %{_tmppath}/%{name}-buildroot |
14 |
|
|
Prefix: %{_prefix} |
15 |
|
|
BuildArchitectures: noarch |
16 |
|
|
BuildRequires: e-smith-devtools |
17 |
|
|
Requires: e-smith-release >= 10.0 |
18 |
|
|
AutoReqProv: no |
19 |
|
|
|
20 |
|
|
%define dir_mngr /usr/share/smanager |
21 |
|
|
|
22 |
|
|
%description |
23 |
|
|
Jsquery and associated plugins plus server-manager (2) specific overrides. |
24 |
|
|
|
25 |
|
|
%changelog |
26 |
brianr |
1.2 |
* Sun Feb 04 2024 Brian Read <brianr@koozali.org> 1.0-2.sme |
27 |
|
|
- Fix-css-override-for-dataTables [SME: 12465] |
28 |
|
|
|
29 |
brianr |
1.1 |
* Mon Jan 29 2024 <brianr@koozali.org> 1.0-1.sme |
30 |
|
|
- Initial code - create RPM [SME:12459] |
31 |
|
|
|
32 |
|
|
%prep |
33 |
|
|
|
34 |
|
|
%setup |
35 |
brianr |
1.2 |
%patch0 -p1 |
36 |
brianr |
1.1 |
|
37 |
|
|
%build |
38 |
|
|
perl createlinks |
39 |
|
|
|
40 |
|
|
%install |
41 |
|
|
rm -rf RPM_BUILD_ROOT |
42 |
|
|
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) |
43 |
|
|
rm -f %{name}-%{version}-filelist |
44 |
|
|
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT \ |
45 |
|
|
> %{name}-%{version}-filelist |
46 |
|
|
#echo "%doc COPYING" >> %{name}-%{version}-filelist |
47 |
|
|
#--dir <dir> 'attr(755,user,grp)' \ |
48 |
|
|
#--file <file> 'attr(755,root,root)' \ |
49 |
|
|
|
50 |
|
|
%clean |
51 |
|
|
cd .. |
52 |
|
|
rm -rf %{name}-%{version} |
53 |
|
|
|
54 |
|
|
%pre |
55 |
|
|
|
56 |
|
|
%preun |
57 |
|
|
|
58 |
|
|
%post |
59 |
|
|
if [ -f /usr/share/javascript/jquery/latest/jquery.min.js ] |
60 |
|
|
then |
61 |
|
|
[ -d %{dir_mngr}/themes/default/public/js ] || |
62 |
|
|
mkdir -p %{dir_mngr}/themes/default/public/js |
63 |
|
|
|
64 |
|
|
[ -h %{dir_mngr}/themes/default/public/js/images ] || |
65 |
|
|
ln -s /usr/share/javascript/jquery-ui/images %{dir_mngr}/themes/default/public/js/images |
66 |
|
|
|
67 |
|
|
|
68 |
|
|
[ -h %{dir_mngr}/themes/default/public/js/jquery.min.js ] || |
69 |
|
|
ln -s /usr/share/javascript/jquery/latest/jquery.min.js %{dir_mngr}/themes/default/public/js/jquery.min.js |
70 |
|
|
[ -h %{dir_mngr}/themes/default/public/js/jquery.min.map ] || |
71 |
|
|
ln -s /usr/share/javascript/jquery/latest/jquery.min.map %{dir_mngr}/themes/default/public/js/jquery.min.map |
72 |
|
|
|
73 |
|
|
[ -h %{dir_mngr}/themes/default/public/js/datatables.min.js ] || |
74 |
|
|
ln -s /usr/share/javascript/datatables.min.js %{dir_mngr}/themes/default/public/js/datatables.min.js |
75 |
|
|
[ -h %{dir_mngr}/themes/default/public/js/datatables.min.css ] || |
76 |
|
|
ln -s /usr/share/javascript/datatables.min.css %{dir_mngr}/themes/default/public/js/datatables.min.css |
77 |
|
|
|
78 |
|
|
[ -h %{dir_mngr}/themes/default/public/js/jquery-ui.min.js ] || |
79 |
|
|
ln -s /usr/share/javascript/jquery-ui/jquery-ui.min.js %{dir_mngr}/themes/default/public/js/jquery-ui.min.js |
80 |
|
|
[ -h %{dir_mngr}/themes/default/public/js/jquery-ui.min.css ] || |
81 |
|
|
ln -s /usr/share/javascript/jquery-ui/jquery-ui.min.css %{dir_mngr}/themes/default/public/js/jquery-ui.min.css |
82 |
|
|
|
83 |
|
|
|
84 |
|
|
fi |
85 |
|
|
true |
86 |
|
|
|
87 |
|
|
|
88 |
|
|
%postun |
89 |
|
|
#uninstall |
90 |
|
|
%files -f %{name}-%{version}-filelist |
91 |
|
|
%defattr(-,root,root) |