File modcopy.spec of Package modcopy
#
# spec file for package modcopy
#
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
# See also http://en.opensuse.org/openSUSE:Specfile_guidelines
%{?!python_module:%define python_module() python3-%{**}}
Name: modcopy
Version: 2009.3
Release: 0
Summary: A tool for copying MOD to MPG with Aspect RATIO
License: BSL-1.0
Group: Productivity/Multimedia/Video/Editors and Convertors
URL: http://modcopy.sourceforge.net/
Source0: http://sourceforge.net/projects/modcopy/files/%{name}/%{version}/%{name}-%{version}.zip
Source1: %{name}.desktop
Source2: %{name}.sh
BuildRequires: dos2unix
BuildRequires: python-rpm-macros
BuildRequires: python2-devel
BuildRequires: unzip
BuildRequires: update-desktop-files
Requires: python
Requires: python-tk
Requires: tix
BuildArch: noarch
%description
A tool for copying video files from memory stick based camcorders
to hard disk. Copies MOD movie files from SD(HC) card and renames
the file extension to MPG. In addition the widescreen flag
is detected in the MOI file and applied to the MPG file.
%prep
%setup -q
dos2unix src/LICENSE
%build
%install
install -d -m0755 %{buildroot}%{python2_sitelib}/%{name}
install -D -m0644 src/*.py %{buildroot}%{python2_sitelib}/%{name}
#%%{__install} -D -m0644 src/*.pyc %%{buildroot}%%{python2_sitelib}/%%{name}
install -D -m0755 %{SOURCE2} %{buildroot}%{_bindir}/%{name}.sh
find %{buildroot}%{_bindir} -type f | xargs sed -i -e 's:@PYTHON_SITELIB@:%{python2_sitelib}:g'
# install dektop
%suse_update_desktop_file -i %{name}
%files
%license src/LICENSE
%{_bindir}/%{name}.sh
%{python2_sitelib}/%{name}/
%{_datadir}/applications/%{name}.desktop
%changelog