building awips2-python-thrift and awips2-python-dynamicserialize within new awips2-python-awips

This commit is contained in:
mjames-upc 2016-03-16 14:25:13 -05:00
parent a3afc324cc
commit 85edb7a33a
2 changed files with 43 additions and 25 deletions

View file

@ -122,14 +122,14 @@ if [ "${1}" = "-pydev" ]; then
#buildRPM "awips2-python-cython"
#buildRPM "awips2-python-metpy"
buildRPM "awips2-python-metpy"
#buildRPM "awips2-python-metpy"
#buildRPM "awips2-python-cartopy"
#buildRPM "awips2-python-numpy"
#buildRPM "awips2-python-scipy"
#buildRPM "awips2-python-matplotlib"
#buildRPM "awips2-python-pyparsing"
#buildRPM "awips2-python-basemap"
#buildRPM "awips2-python-awips"
buildRPM "awips2-python-awips"
# DONE
#buildRPM "awips2-python-pint"

View file

@ -1,29 +1,30 @@
%global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompile[[:space:]].*$!!g')
%define _build_arch %(uname -i)
%define _python_pkgs_dir "%{_baseline_workspace}/pythonPackages"
%define _python_build_loc %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
#
# AWIPS II Python DAF Spec File
# AWIPS II Python awips Spec File
#
Name: awips2-python-awips
Summary: AWIPS II Python DAF Distribution
Version: %{_component_version}
Release: %{_component_release}
Summary: AWIPS II Python awips Distribution
Version: 0.9.3
Release: 1
Group: AWIPSII
BuildRoot: %{_build_root}
BuildArch: noarch
BuildArch: %{_build_arch}
URL: N/A
License: N/A
Distribution: N/A
Vendor: Raytheon
Packager: Bryan Kowal
Vendor: Unidata
Packager: Michael James
AutoReq: no
requires: awips2-python
provides: awips2-python-awips
%description
AWIPS II Python DAF Site-Package - 64-bit.
AWIPS II Python Awips Site-Package
%prep
# Verify That The User Has Specified A BuildRoot.
@ -35,32 +36,49 @@ then
fi
rm -rf %{_build_root}
if [ $? -ne 0 ]; then
exit 1
mkdir -p %{_build_root}
if [ -d %{_python_build_loc} ]; then
rm -rf %{_python_build_loc}
fi
mkdir -p %{_python_build_loc}
%build
AWIPS_SRC_DIR="%{_python_pkgs_dir}/python-awips"
%install
mkdir -p %{_build_root}/awips2/python/lib/python2.7/site-packages/awips
if [ $? -ne 0 ]; then
cp -rv ${AWIPS_SRC_DIR}/* \
%{_python_build_loc}
RC=$?
if [ ${RC} -ne 0 ]; then
exit 1
fi
UFPY_SRC_DIR="%{_python_pkgs_dir}/awips"
cp -rv ${UFPY_SRC_DIR}/* \
%{_build_root}/awips2/python/lib/python2.7/site-packages/awips
pushd . > /dev/null
cd %{_python_build_loc}
export LD_LIBRARY_PATH=/awips2/python/lib
/awips2/python/bin/python setup.py build
RC=$?
if [ ${RC} -ne 0 ]; then
exit 1
fi
popd > /dev/null
%pre
%install
%post
%preun
%postun
pushd . > /dev/null
cd %{_python_build_loc}
export LD_LIBRARY_PATH=/awips2/python/lib
/awips2/python/bin/python setup.py install \
--root=%{_build_root} \
--prefix=/awips2/python
RC=$?
if [ ${RC} -ne 0 ]; then
exit 1
fi
popd > /dev/null
%clean
rm -rf %{_build_root}
rm -rf %{_python_build_loc}
%files
%defattr(644,awips,fxalpha,755)