95 lines
1.9 KiB
RPMSpec
95 lines
1.9 KiB
RPMSpec
|
%global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompile[[:space:]].*$!!g')
|
||
|
|
||
|
%define _python_pkgs_dir "%{_baseline_workspace}/pythonPackages"
|
||
|
|
||
|
#
|
||
|
# AWIPS II Python pygtk Spec File
|
||
|
#
|
||
|
Name: awips2-python-pygtk
|
||
|
Summary: AWIPS II Python pygtk Distribution
|
||
|
Version: 2.8.6
|
||
|
Release: 1
|
||
|
Group: AWIPSII
|
||
|
BuildRoot: %{_build_root}
|
||
|
URL: N/A
|
||
|
License: N/A
|
||
|
Distribution: N/A
|
||
|
Vendor: Raytheon
|
||
|
Packager: Bryan Kowal
|
||
|
|
||
|
AutoReq: no
|
||
|
requires: awips2-python
|
||
|
requires: awips2-python-pycairo
|
||
|
provides: awips2-python-pygtk
|
||
|
|
||
|
%description
|
||
|
AWIPS II Python pygtk Site-Package.
|
||
|
|
||
|
%prep
|
||
|
# Verify That The User Has Specified A BuildRoot.
|
||
|
if [ "%{_build_root}" = "/tmp" ]
|
||
|
then
|
||
|
echo "An Actual BuildRoot Must Be Specified. Use The --buildroot Parameter."
|
||
|
echo "Unable To Continue ... Terminating"
|
||
|
exit 1
|
||
|
fi
|
||
|
|
||
|
rm -rf %{_build_root}
|
||
|
mkdir -p %{_build_root}
|
||
|
mkdir -p %{_build_root}/build-python
|
||
|
|
||
|
PYGTK_SRC_DIR="%{_python_pkgs_dir}/pygtk"
|
||
|
PYGTK_TAR="pygtk-2.8.6.tar.gz"
|
||
|
|
||
|
cp -v ${PYGTK_SRC_DIR}/${PYGTK_TAR} \
|
||
|
%{_build_root}/build-python
|
||
|
if [ $? -ne 0 ]; then
|
||
|
exit 1
|
||
|
fi
|
||
|
|
||
|
pushd . > /dev/null
|
||
|
cd %{_build_root}/build-python
|
||
|
tar -xvf ${PYGTK_TAR}
|
||
|
if [ $? -ne 0 ]; then
|
||
|
exit 1
|
||
|
fi
|
||
|
popd > /dev/null
|
||
|
|
||
|
%build
|
||
|
pushd . > /dev/null
|
||
|
cd %{_build_root}/build-python/pygtk-2.8.6
|
||
|
./configure --prefix=%{_build_root}/awips2/python
|
||
|
if [ $? -ne 0 ]; then
|
||
|
exit 1
|
||
|
fi
|
||
|
make
|
||
|
if [ $? -ne 0 ]; then
|
||
|
exit 1
|
||
|
fi
|
||
|
popd > /dev/null
|
||
|
|
||
|
%install
|
||
|
pushd . > /dev/null
|
||
|
cd %{_build_root}/build-python/pygtk-2.8.6
|
||
|
make install
|
||
|
if [ $? -ne 0 ]; then
|
||
|
exit 1
|
||
|
fi
|
||
|
popd > /dev/null
|
||
|
|
||
|
rm -rf %{_build_root}/build-python
|
||
|
|
||
|
%clean
|
||
|
rm -rf ${RPM_BUILD_ROOT}
|
||
|
|
||
|
%files
|
||
|
%defattr(644,awips,fxalpha,755)
|
||
|
%dir /awips2/python/lib
|
||
|
/awips2/python/lib/*
|
||
|
%dir /awips2/python/include
|
||
|
/awips2/python/include/*
|
||
|
%dir /awips2/python/share
|
||
|
/awips2/python/share/*
|
||
|
%defattr(755,awips,fxalpha,755)
|
||
|
%dir /awips2/python/bin
|
||
|
/awips2/python/bin/*
|