Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Yershov <yershov@corp.mail.ru>2017-08-03 17:02:09 +0300
committerRoman Kuznetsov <r.kuznetsow@gmail.com>2017-08-03 17:14:33 +0300
commita02c0339b4a7c1658af44d193356d33455bde9dc (patch)
tree39511799c92d83b21da0f24b71ab8ada65fc83cd /pyhelpers
parent0f63abb4d0ccba8d3366661fbb19e4840df16e4a (diff)
Fix build pymodules on Linuxpy-modules-0.2.3
Diffstat (limited to 'pyhelpers')
-rwxr-xr-xpyhelpers/specs/build.sh30
-rw-r--r--pyhelpers/specs/python35-mapsme-modules.spec14
2 files changed, 38 insertions, 6 deletions
diff --git a/pyhelpers/specs/build.sh b/pyhelpers/specs/build.sh
new file mode 100755
index 0000000000..e357e713f4
--- /dev/null
+++ b/pyhelpers/specs/build.sh
@@ -0,0 +1,30 @@
+#!/bin/bash
+PROJECT=$1
+VERSION=$2
+RELEASE=$3
+if [ -z "$PROJECT" ]; then
+ echo "Specify project as first parameter"
+ exit 1
+fi
+if [ -z "$VERSION" ]; then
+ echo "Specify version as second parameter"
+ exit 1
+fi
+if [ -z "$RELEASE" ]; then
+ RELEASE=1
+fi
+
+basedir=`dirname $0`
+PROJECT=$PROJECT VERSION=$VERSION RELEASE=$RELEASE rpmbuild -ba python35-mapsme-modules.spec
+if [ $? -ne 0 ]; then
+ echo "Build failed!"
+ exit
+fi
+
+#rsync -av $HOME/rpmbuild/RPMS/noarch/$PROJECT.maps.me-{meta,front,devel}-$VERSION-$RELEASE.el6.noarch.rpm mapsme-team@pkg.corp.mail.ru::c6-mapsme-noarch
+#rsync -av $HOME/rpmbuild/RPMS/x86_64/$PROJECT.maps.me-$VERSION-$RELEASE.el6.x86_64.rpm mapsme-team@pkg.corp.mail.ru::c6-mapsme-x64
+
+#echo "c6-mapsme-noarch" | nc pkg.corp.mail.ru 12222 | grep -v '^* c'
+#echo "c6-mapsme-x64" | nc pkg.corp.mail.ru 12222 | grep -v '^* c'
+#echo
+echo "$PROJECT packages version $VERSION-$RELEASE build done, ready to deploy"
diff --git a/pyhelpers/specs/python35-mapsme-modules.spec b/pyhelpers/specs/python35-mapsme-modules.spec
index 328a3ba643..c8afaf730f 100644
--- a/pyhelpers/specs/python35-mapsme-modules.spec
+++ b/pyhelpers/specs/python35-mapsme-modules.spec
@@ -21,10 +21,9 @@
%{!?__jar_repack:/usr/lib/rpm/redhat/brp-java-repack-jars} \
%{nil}
-%define unmangled_version 0.1.7
-%define version %{unmangled_version}
-%define release 1
-%define tag py-modules-%{unmangled_version}
+%define version %(echo $VERSION)
+%define release %(echo $RELEASE)
+%define tag py-modules-%{version}
Name: python35-mapsme-modules
Version: %{version}
@@ -35,7 +34,7 @@ Vendor: Mail.Ru Group
Group: Development/Languages/Python
URL: https://github.com/mapsme/omim
-Source: omim-py-modules-%{unmangled_version}.tar.gz
+Source: omim-py-modules-%{version}.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
Prefix: %{_prefix}
@@ -82,11 +81,13 @@ cd ..
%{__mkdir_p} build && cd build
# TODO(mgergio, yershov): Why should we stills specify PYTHON_LIBRARY and
# PYTHON_INCLUDE_DIR manually?
-%{__cmake3} -DPYTHON_LIBRARY=/usr/local/python35/lib/libpython3.so -DPYTHON_INCLUDE_DIR=/usr/local/python35/include/python3.5m/ -DPYTHON_VERSION=3.5 -DBOOST_INCLUDEDIR=/usr/local/boost_1.54.0/include/ -DPYBINDINGS=ON ../omim
+%{__cmake3} -DPYTHON_LIBRARY=/usr/local/python35/lib/libpython3.so -DPYTHON_INCLUDE_DIR=/usr/local/python35/include/python3.5m/ -DPYTHON_VERSION=3.5 -DBOOST_INCLUDEDIR=/usr/local/boost_1.54.0/include/ -DPYBINDINGS=ON -DSKIP_DESKTOP=ON ../omim
%{__make} %{?_smp_mflags} pylocal_ads
+%{__make} %{?_smp_mflags} pymwm_diff
%install
%{__install} -m 755 -D %{_builddir}/%{name}-%{version}/build/pylocal_ads.so %{buildroot}/%{python_sitelib}/pylocal_ads.so
+%{__install} -m 755 -D %{_builddir}/%{name}-%{version}/build/pymwm_diff.so %{buildroot}/%{python_sitelib}/pymwm_diff.so
%clean
rm -rf %{buildroot}
@@ -94,6 +95,7 @@ rm -rf %{buildroot}
%files -n python35-pylocal_ads
%defattr(-,root,root)
%{python_sitelib}/pylocal_ads.so
+%{python_sitelib}/pymwm_diff.so
%changelog
* Wed Apr 26 2017 Magidovich Sergey <s.magidovich@corp.mail.ru> - 0.1b-1