84 lines
2.6 KiB
RPMSpec
84 lines
2.6 KiB
RPMSpec
%define name smeserver-manager-jsquery
|
|
%define version 1.0
|
|
%define release 1
|
|
Summary: Jsquery and associated plugins plus server-manager (2) specific overrides.
|
|
Name: %{name}
|
|
Version: %{version}
|
|
Release: %{release}%{?dist}
|
|
Source: %{name}-%{version}.tar.gz
|
|
License: GNU GPL version 2
|
|
Group: SMEserver/addon
|
|
BuildRoot: %{_tmppath}/%{name}-buildroot
|
|
Prefix: %{_prefix}
|
|
BuildArchitectures: noarch
|
|
BuildRequires: e-smith-devtools
|
|
Requires: e-smith-release >= 10.0
|
|
AutoReqProv: no
|
|
|
|
%description
|
|
Jsquery and associated plugins plus server-manager (2) specific overrides.
|
|
|
|
%changelog
|
|
* Mon Jan 29 2024 <brianr@koozali.org> 1.0-1.sme
|
|
- Initial code - create RPM [SME:12459]
|
|
|
|
%prep
|
|
|
|
%setup
|
|
|
|
%build
|
|
perl createlinks
|
|
|
|
%install
|
|
rm -rf RPM_BUILD_ROOT
|
|
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
|
|
rm -f %{name}-%{version}-filelist
|
|
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT \
|
|
> %{name}-%{version}-filelist
|
|
#echo "%doc COPYING" >> %{name}-%{version}-filelist
|
|
#--dir <dir> 'attr(755,user,grp)' \
|
|
#--file <file> 'attr(755,root,root)' \
|
|
|
|
%clean
|
|
cd ..
|
|
rm -rf %{name}-%{version}
|
|
|
|
%pre
|
|
|
|
%preun
|
|
|
|
%post
|
|
if [ -f /usr/share/javascript/jquery/latest/jquery.min.js ]
|
|
then
|
|
[ -d %{dir_mngr}/themes/default/public/js ] ||
|
|
mkdir %{dir_mngr}/themes/default/public/js
|
|
[ -h %{dir_mngr}/themes/default/public/js/jquery.min.js ] ||
|
|
ln -s /usr/share/javascript/jquery/latest/jquery.min.js %{dir_mngr}/themes/default/public/js/jquery.min.js
|
|
[ -h %{dir_mngr}/themes/default/public/js/jquery.min.map ] ||
|
|
ln -s /usr/share/javascript/jquery/latest/jquery.min.map %{dir_mngr}/themes/default/public/js/jquery.min.map
|
|
|
|
[ -h %{dir_mngr}/themes/default/public/js/datatables.min.js ] ||
|
|
ln -s /usr/share/javascript/datatables.min.js %{dir_mngr}/themes/default/public/js/datatables.min.js
|
|
[ -h %{dir_mngr}/themes/default/public/js/datatable.min.css ] ||
|
|
ln -s /usr/share/javascript/datatables.min.css %{dir_mngr}/themes/default/public/js/jquery.min.css
|
|
|
|
[ -h %{dir_mngr}/themes/default/public/js/jquery-ui.min.js ] ||
|
|
ln -s /usr/share/javascript/jquery-ui/jquery-ui.min.js %{dir_mngr}/themes/default/public/js/jquery-ui.min.js
|
|
[ -h %{dir_mngr}/themes/default/public/js/jquery-ui.min.css ] ||
|
|
ln -s /usr/share/javascript/jquery-ui/jquery-ui.min.css %{dir_mngr}/themes/default/public/js/jquery-ui.min.css
|
|
[ -h %{dir_mngr}/themes/default/public/js/jquery-ui.theme.min.css ] ||
|
|
ln -s /usr/share/javascript/jquery-ui/jquery-ui.theme.min.css %{dir_mngr}/themes/default/public/js/jquery-ui.theme.min.css
|
|
|
|
|
|
|
|
|
|
|
|
fi
|
|
true
|
|
|
|
|
|
%postun
|
|
#uninstall
|
|
%files -f %{name}-%{version}-filelist
|
|
%defattr(-,root,root)
|