summaryrefslogtreecommitdiff
path: root/veracrypt/veracrypt.spec
diff options
context:
space:
mode:
authorB Stack <bgstack15@gmail.com>2018-09-02 08:43:30 -0400
committerB Stack <bgstack15@gmail.com>2018-09-02 08:43:30 -0400
commitcc654a123b8b60877fca74308008ff2249a72a06 (patch)
treef646dcc0998c71548b0dc85bbd0bd16c25ab318b /veracrypt/veracrypt.spec
parentfinal cleanup of gcc49 spec (diff)
downloadstackrpms-cc654a123b8b60877fca74308008ff2249a72a06.tar.gz
stackrpms-cc654a123b8b60877fca74308008ff2249a72a06.tar.bz2
stackrpms-cc654a123b8b60877fca74308008ff2249a72a06.zip
add veracrypt
Diffstat (limited to 'veracrypt/veracrypt.spec')
-rw-r--r--veracrypt/veracrypt.spec134
1 files changed, 134 insertions, 0 deletions
diff --git a/veracrypt/veracrypt.spec b/veracrypt/veracrypt.spec
new file mode 100644
index 0000000..7b6c2df
--- /dev/null
+++ b/veracrypt/veracrypt.spec
@@ -0,0 +1,134 @@
+%global pname VeraCrypt
+%global dummy_package 0
+%global tarballdir %{pname}_%{version}
+%global srcdir %{tarballdir}/src
+%global indocdir %{tarballdir}/doc
+%define license_files src/License.txt
+%define debug_package %{nil}
+
+Name: veracrypt
+Version: 1.22
+Release: 1
+Summary: Disk encryption with strong security based on TrueCrypt
+
+Group: Applications/File
+License: Apache License 2.0 and TrueCrypt License 3.0
+URL: https://www.veracrypt.fr/
+Source0: https://www.veracrypt.fr/code/%{pname}/snapshot/%{pname}_%{version}.tar.gz
+# in case upstream ever malfunctions here is my mirror
+#Source0: https://gitlab.com/bgstack15/big-sources/raw/master/%{name}/%{pname}_%{version}.tar.gz
+Patch0: vc_fedora.patch
+Patch1: vc_desktop.patch
+
+Packager: Bgstack15 <bgstack15@gmail.com>
+BuildRequires: gcc-c++
+BuildRequires: wxGTK3-devel
+BuildRequires: fuse-devel
+BuildRequires: desktop-file-utils
+BuildRequires: ImageMagick
+Requires: wxGTK3
+
+%description
+VeraCrypt is a free open source disk encryption software for Windows, Mac OSX and Linux. Brought to you by IDRIX (https://www.idrix.fr) and based on TrueCrypt 7.1a.
+
+%prep
+%setup -q -c
+
+%patch0 -p0
+%patch1 -p0
+
+%build
+#%make_build -C %{tarballdir}/src
+pushd %{srcdir}
+make %{_smp_mflags}
+popd
+
+%install
+#%make_install -C %{tarballdir}/src
+%{__install} -d "%{buildroot}%{_bindir}"
+%{__install} %{srcdir}/Main/veracrypt "%{buildroot}%{_bindir}"
+%{__install} -d "%{buildroot}%{_docdir}/%{name}"
+%{__install} -m 0644 %{srcdir}/License.txt "%{buildroot}%{_docdir}/%{name}"
+%{__install} -d "%{buildroot}%{_datadir}/applications" "%{buildroot}%{_datadir}/pixmaps"
+%{__install} %{srcdir}/Setup/Linux/%{name}.desktop "%{buildroot}%{_datadir}/applications"
+%{__install} %{srcdir}/Resources/Icons/VeraCrypt-256x256.xpm "%{buildroot}%{_datadir}/pixmaps/veracrypt.xpm"
+
+# cleanup
+
+# desktop files
+test -f %{srcdir}/Setup/Linux/%{name}.desktop && \
+ %{__install} -p -D -m 0644 "%{srcdir}/Setup/Linux/%{name}.desktop" "%{buildroot}%{_datadir}/applications/%{name}.desktop" || :
+
+# application start script
+# none
+
+# man pages
+# handled by the %files %doc directive?
+# not really man pages in this case, just html and text
+#for thisdir in $( find %{indocdir} -mindepth 1 -maxdepth 1 -printf '%f\n' ) ;
+#do
+# %{__install} -p -D -d %{indocdir}/${thisdir} %{buildroot}%{_defaultdocdir}/%{name}/${thisdir}
+#done
+
+# icons
+pushd %{srcdir}/Resources/Icons
+for s in {16,48,128,256} ;
+do
+ convert "%{pname}-${s}x${s}.xpm" "%{pname}-${s}x${s}.png" && \
+ %{__install} -p -D -m 0644 "%{pname}-${s}x${s}.png" "%{buildroot}%{_datadir}/icons/hicolor/${s}x${s}/apps/%{name}.png" || :
+done
+popd
+
+for e in {xpm,png} ;
+do
+ test -f "%{srcdir}/Resources/Icons/%{pname}-256x256.${e}" || continue
+ %{__install} -p -D -m 0644 "%{srcdir}/Resources/Icons/%{pname}-256x256.${e}" "%{buildroot}%{_datadir}/pixmaps/%{name}.${e}"
+done
+
+:
+
+%clean
+rm -rf %{buildroot} || :
+
+%post
+touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
+/usr/bin/update-mime-database "%{_datadir}/mime" &>/dev/null || :
+update-desktop-database &> /dev/null || :
+/sbin/ldconfig || :
+
+%preun
+# is it a final removal?
+#if test "$1" = "0" ;
+#then
+#fi
+
+%postun
+update-desktop-database &> /dev/null || :
+if test "$1" = "0" ;
+then
+ touch --no-create %{_datadir}/icons/hicolor &>/dev/null
+ gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
+ /usr/bin/update-mime-database "%{_datadir}/mime" &>/dev/null || :
+fi
+/sbin/ldconfig || :
+
+%posttrans
+/usr/bin/gtk-update-icon-cache "%{_datadir}/icons/hicolor" &>/dev/null || :
+/usr/bin/update-mime-database "%{_datadir}/mime" &>/dev/null || :
+
+%files
+%if 0%{?doc_license}
+%license %{license_files}
+%else
+%doc %{license_files}
+%endif
+%doc "%{indocdir}/chm/VeraCrypt User Guide.chm" %{indocdir}/EFI-DCS/ %{indocdir}/html/
+%{_bindir}/%{name}
+#%{_docdir}/%{name} # handled by %doc above?
+%{_datadir}/applications/*.desktop
+%{_datadir}/pixmaps/*
+%{_datadir}/icons/hicolor/*/apps/*
+
+%changelog
+* Sat Sep 1 2018 B Stack <bgstack15@gmail.com> 1.22-1
+- Initial rpm built.
bgstack15