Optimization the spec
This commit is contained in:
parent
9bbe58bb0c
commit
e07dc7c60a
@ -22,7 +22,7 @@ index b747045..2b1ac8d 100644
|
|||||||
-
|
-
|
||||||
+ print(sysconfig.get_python_lib(0,0))
|
+ print(sysconfig.get_python_lib(0,0))
|
||||||
diff --git a/configure.ac b/configure.ac
|
diff --git a/configure.ac b/configure.ac
|
||||||
index 51166c3..4d8c9a0 100644
|
index 51166c3..0f18965 100644
|
||||||
--- a/configure.ac
|
--- a/configure.ac
|
||||||
+++ b/configure.ac
|
+++ b/configure.ac
|
||||||
@@ -1142,7 +1142,7 @@ else
|
@@ -1142,7 +1142,7 @@ else
|
||||||
@ -34,20 +34,18 @@ index 51166c3..4d8c9a0 100644
|
|||||||
if test "x$PYTHON" = "x"; then
|
if test "x$PYTHON" = "x"; then
|
||||||
use_python="No (python not available)"
|
use_python="No (python not available)"
|
||||||
else
|
else
|
||||||
@@ -1167,8 +1167,11 @@ else
|
@@ -1167,8 +1167,8 @@ else
|
||||||
if test "x$PYTHON" = "x"; then
|
if test "x$PYTHON" = "x"; then
|
||||||
use_python="No (python is too old)"
|
use_python="No (python is too old)"
|
||||||
else
|
else
|
||||||
- PYTHON_PREFIX=`$PYTHON -c "import sys; print sys.prefix"`
|
- PYTHON_PREFIX=`$PYTHON -c "import sys; print sys.prefix"`
|
||||||
|
- PYTHON_INCLUDES=-I$PYTHON_PREFIX/include/python$PYTHON_VERSION_SHORT
|
||||||
+ PYTHON_PREFIX=`$PYTHON -c "import sys; print(sys.prefix)"`
|
+ PYTHON_PREFIX=`$PYTHON -c "import sys; print(sys.prefix)"`
|
||||||
PYTHON_INCLUDES=-I$PYTHON_PREFIX/include/python$PYTHON_VERSION_SHORT
|
+ PYTHON_INCLUDES=`$PYTHON-config --includes`
|
||||||
+ if test $PYTHON_VERSION_MAJOR -gt 2; then
|
|
||||||
+ PYTHON_INCLUDES="${PYTHON_INCLUDES}m"
|
|
||||||
+ fi
|
|
||||||
# PYTHON_LIBS="-lpython$PYTHON_VERSION_SHORT"
|
# PYTHON_LIBS="-lpython$PYTHON_VERSION_SHORT"
|
||||||
PYTHON_LIBS="-undefined dynamic_lookup"
|
PYTHON_LIBS="-undefined dynamic_lookup"
|
||||||
PYTHON_INSTALL_DIR="`$PYTHON $srcdir/config/config_python.py archsitelib`"
|
PYTHON_INSTALL_DIR="`$PYTHON $srcdir/config/config_python.py archsitelib`"
|
||||||
@@ -1548,7 +1551,7 @@ else
|
@@ -1548,7 +1548,7 @@ else
|
||||||
if test "x$PYTHON34" = "x"; then
|
if test "x$PYTHON34" = "x"; then
|
||||||
use_python34="No (python34 is too old)"
|
use_python34="No (python34 is too old)"
|
||||||
else
|
else
|
||||||
|
|||||||
@ -16,7 +16,7 @@
|
|||||||
|
|
||||||
Name: graphviz
|
Name: graphviz
|
||||||
Version: 2.40.1
|
Version: 2.40.1
|
||||||
Release: 38
|
Release: 39
|
||||||
Summary: Graph Visualization Tools
|
Summary: Graph Visualization Tools
|
||||||
License: EPL
|
License: EPL
|
||||||
URL: http://www.graphviz.org/
|
URL: http://www.graphviz.org/
|
||||||
@ -172,9 +172,10 @@ export CPPFLAGS=-I`ruby -e "puts File.join(RbConfig::CONFIG['includedir'], RbCon
|
|||||||
cp -a tclpkg/gv tclpkg/gv.python2
|
cp -a tclpkg/gv tclpkg/gv.python2
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%make_build CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing -fno-strict-overflow %{?FFSTORE}" \
|
|
||||||
|
make %{?_smp_mflags} CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing -fno-strict-overflow %{?FFSTORE}" \
|
||||||
CXXFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing -fno-strict-overflow %{?FFSTORE}" \
|
CXXFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing -fno-strict-overflow %{?FFSTORE}" \
|
||||||
PYTHON_INCLUDES=-I/usr/include/python%{python3_version}m PYTHON_LIBS="-lpython%{python3_version}m" \
|
PYTHON_INCLUDES=`python3-config --includes` PYTHON_LIBS=`python3-config --libs` \
|
||||||
PYTHON_INSTALL_DIR=%{python3_sitearch} PYTHON=%{__python3}
|
PYTHON_INSTALL_DIR=%{python3_sitearch} PYTHON=%{__python3}
|
||||||
|
|
||||||
%if %{with python2}
|
%if %{with python2}
|
||||||
@ -188,9 +189,12 @@ cd tclpkg/gv.python2
|
|||||||
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%make_install docdir=%{buildroot}%{_docdir}/%{name} \
|
make DESTDIR=%{buildroot} \
|
||||||
pkgconfigdir=%{_libdir}/pkgconfig PYTHON_LIBS="-lpython%{python3_version}m" \
|
docdir=%{buildroot}%{_docdir}/%{name} \
|
||||||
PYTHON_INSTALL_DIR=%{python3_sitearch} install
|
pkgconfigdir=%{_libdir}/pkgconfig \
|
||||||
|
PYTHON_LIBS=`python3-config --libs` \
|
||||||
|
PYTHON_INSTALL_DIR=%{python3_sitearch} \
|
||||||
|
install
|
||||||
|
|
||||||
%delete_la
|
%delete_la
|
||||||
|
|
||||||
@ -317,6 +321,12 @@ php --no-php-ini --define extension_dir=$RPM_BUILD_ROOT%{_libdir}/graphviz/php/
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Jun 23 2020 xinghe <xinghe1@huawei.com> - 2.40.1-39
|
||||||
|
- Type:bugfix
|
||||||
|
- ID:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC:optimization the spec
|
||||||
|
|
||||||
* Tue Dec 31 2019 openEuler Buildteam <buildteam@openeuler.org> - 2.40.1-38
|
* Tue Dec 31 2019 openEuler Buildteam <buildteam@openeuler.org> - 2.40.1-38
|
||||||
- Type:bugfix
|
- Type:bugfix
|
||||||
- ID:NA
|
- ID:NA
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user