mirror of
https://abf.rosa.ru/djam/fakesmtp.git
synced 2025-02-23 16:52:56 +00:00
67 lines
1.4 KiB
RPMSpec
67 lines
1.4 KiB
RPMSpec
%define oname FakeSMTP
|
|
|
|
Name: fakesmtp
|
|
Version: 2.0
|
|
Release: 1
|
|
Summary: Fake SMTP Server with GUI for testing emails
|
|
URL: http://nilhcem.github.io/FakeSMTP/
|
|
Source0: %{oname}-%{version}.tar.gz
|
|
License: BSD
|
|
Group: Development/Other
|
|
BuildArch: noarch
|
|
BuildRequires: java-devel
|
|
BuildRequires: maven
|
|
|
|
|
|
%description
|
|
FakeSMTP is a Free Fake SMTP Server with GUI for
|
|
testing emails in applications easily. It is written in Java.
|
|
|
|
%prep
|
|
%setup -qn %{oname}-%{version}
|
|
|
|
%build
|
|
mvn package
|
|
|
|
%install
|
|
install -d %{buildroot}%{_bindir}
|
|
install -d %{buildroot}%{_datadir}/%{name}
|
|
install -d %{buildroot}%{_iconsdir}
|
|
install -Dm0644 target/fakeSMTP-2.0.jar %{buildroot}/%{_datadir}/%{name}/%{name}.jar
|
|
|
|
pushd target/classes
|
|
convert icon.gif %{buildroot}%{_iconsdir}/%{name}.png
|
|
popd
|
|
|
|
# start script
|
|
cat > %{buildroot}%{_bindir}/%{name} <<EOF
|
|
#!/bin/bash
|
|
java -jar %{_datadir}/%{name}/%{name}.jar
|
|
EOF
|
|
|
|
chmod +x %{buildroot}%{_bindir}/%{name}
|
|
|
|
# menu-entry
|
|
install -d %{buildroot}%{_datadir}/applications
|
|
cat > %{buildroot}%{_datadir}/applications/%{name}.desktop <<EOF
|
|
[Desktop Entry]
|
|
Name=FakeSMTP
|
|
Name[ru]=FakeSMTP
|
|
GenericName=FakeSMTP
|
|
GenericName[ru]=
|
|
Comment=Proxy SMTP for tests
|
|
Comment[ru]=Тестирование SMTP
|
|
Exec=%{name}
|
|
Icon=%{name}
|
|
Terminal=false
|
|
Type=Application
|
|
StartupNotify=true
|
|
Categories=Application;
|
|
EOF
|
|
|
|
%files
|
|
%doc LICENSE.txt README.md
|
|
%{_bindir}/%{name}
|
|
%{_datadir}/%{name}/*
|
|
%{_iconsdir}/%{name}.png
|
|
%{_datadir}/applications/%{name}.desktop
|