1
0
forked from pool/mapserver

Accepting request 368007 from home:rhabacker:branches:Application:Geo

- Add xxxx-fix-python-mapscript-soversion-install-issue.patch to fix broken installing of mapscript python module 
- Exclude ruby from build for sles11 because of missing ruby dependencies
- Use ruby-common as build dependency instead of outdated ruby-macros

OBS-URL: https://build.opensuse.org/request/show/368007
OBS-URL: https://build.opensuse.org/package/show/Application:Geo/mapserver?expand=0&rev=101
This commit is contained in:
Martin Pluskal 2016-03-08 12:02:44 +00:00 committed by Git OBS Bridge
parent f52bfdff10
commit ea07ce2172
4 changed files with 53 additions and 4 deletions

View File

@ -7,7 +7,7 @@ index 33945b2..a14c246 100644
set_target_properties(${SWIG_MODULE_pythonmapscript_REAL_NAME} PROPERTIES PREFIX "")
-set_target_properties(${SWIG_MODULE_pythonmapscript_REAL_NAME} PROPERTIES OUTPUT_NAME _mapscript)
+set_target_properties(${SWIG_MODULE_pythonmapscript_REAL_NAME} PROPERTIES OUTPUT_NAME python_mapscript)
+set_target_properties(${SWIG_MODULE_pythonmapscript_REAL_NAME} PROPERTIES OUTPUT_NAME _mapscript)
+
+if(NOT APPLE)
+ set_target_properties(${SWIG_MODULE_pythonmapscript_REAL_NAME} PROPERTIES

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Tue Mar 8 07:02:53 UTC 2016 - ralf.habacker@freenet.de
- Add xxxx-fix-python-mapscript-soversion-install-issue.patch to fix
broken installing of mapscript python module
- Exclude ruby from build for sles11 because of missing ruby dependencies
- Use ruby-common as build dependency instead of outdated ruby-macros
-------------------------------------------------------------------
Fri Feb 5 14:22:24 UTC 2016 - guillaume@opensuse.org

View File

@ -19,7 +19,11 @@
#
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%if 0%{?sles_version} != 11
%define _with_ruby 1
%endif
%bcond_with ruby
%define fileversion 6.4.1
%define libname libmapserver1
%define python_sitearch %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")
@ -43,6 +47,7 @@ Patch5: 4912-php56-php-input.patch
# Fix Build with GIFLIB >= 5.1.0
Patch6: giflib_5.1.0.patch
Patch7: swig_3.patch
Patch8: xxxx-fix-python-mapscript-soversion-install-issue.patch
BuildRequires: FastCGI-devel
BuildRequires: apache2-devel
BuildRequires: autoconf
@ -83,6 +88,9 @@ BuildRequires: libcurl-devel
%if 0%{?suse_version} != 1010
BuildRequires: xorg-x11-libXpm-devel
%endif
%if 0%{?sles_version} == 11 || %{?suse_version} == 1310
BuildRequires: libhdf4
%endif
Requires: %{libname} = %{version}-%{release}
Requires: FastCGI
Requires: apache2
@ -149,8 +157,12 @@ within the Perl programming language.
Summary: Python/Mapscript map making extensions to Python
Group: Development/Languages/Python
BuildRequires: python-devel
Requires: %{libname} = %{version}-%{release}
Requires: python-base
%if 0%{?sles_version} != 11
BuildRequires: python3-devel
Requires: python3-base
%endif
Requires: %{libname} = %{version}-%{release}
Provides: mapserver-python = %{version}-%{release}
Obsoletes: mapserver-python < %{version}-%{release}
@ -181,11 +193,12 @@ BuildRequires: java-1_5_0-ibm-alsa
The Java/Mapscript extension provides full map customization capabilities
within the Java programming language.
%if %{with ruby}
%package -n ruby-mapscript
Summary: Ruby/Mapscript map making extensions to Ruby
Group: Development/Languages/Ruby
BuildRequires: ruby-devel
BuildRequires: ruby-macros
BuildRequires: ruby-common
Requires: %{libname} = %{version}-%{release}
Requires: ruby
Provides: mapserver-ruby = %{version}-%{release}
@ -194,6 +207,7 @@ Obsoletes: mapserver-ruby < %{version}-%{release}
%description -n ruby-mapscript
The Ruby/Mapscript extension provides full map customization capabilities
within the Ruby programming language.
%endif
%package devel
Summary: Mapserver development files
@ -213,6 +227,7 @@ against the C Mapserver library.
%patch5 -p1
%patch6 -p0
%patch7 -p0
%patch8 -p1
%build -n %{name}-%{fileversion}
@ -257,7 +272,9 @@ cmake -DCMAKE_INSTALL_PREFIX=%{_prefix} \
-DWITH_POSTGIS=TRUE \
-DWITH_PROJ=TRUE \
-DWITH_PYTHON=TRUE \
%if %{with ruby}
-DWITH_RUBY=TRUE \
%endif
-DWITH_SOS=TRUE \
-DWITH_THREAD_SAFETY=TRUE \
-DWITH_WCS=TRUE \
@ -389,12 +406,13 @@ rm -rf %{buildroot}
%doc mapscript/java/tests
%{_libdir}/libjavamapscript.so
%if %{with ruby}
%files -n ruby-mapscript
%defattr(-,root,root)
%doc mapscript/ruby/README
%doc mapscript/ruby/examples
%{rb_sitearchdir}/mapscript.so
%endif
%files devel
%defattr(-,root,root)

View File

@ -0,0 +1,23 @@
--- a/mapscript/python/CMakeLists.txt 2016-01-08 12:54:36.040215116 +0000
+++ b/mapscript/python/CMakeLists.txt 2016-01-08 12:58:24.534402782 +0000
@@ -46,9 +46,5 @@
execute_process ( COMMAND ${PYTHON_EXECUTABLE} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(True)" OUTPUT_VARIABLE PYTHON_SITE_PACKAGES OUTPUT_STRIP_TRAILING_WHITESPACE)
-get_target_property(LOC_MAPSCRIPT_LIB ${SWIG_MODULE_pythonmapscript_REAL_NAME} LOCATION)
-set(mapscript_files ${LOC_MAPSCRIPT_LIB} ${CMAKE_CURRENT_BINARY_DIR}/mapscript.py)
-install(FILES ${mapscript_files} DESTINATION ${PYTHON_SITE_PACKAGES})
-
-#install(FILES ${CMAKE_CURRENT_BINARY_DIR}/mapscript.py DESTINATION ${PYTHON_SITE_PACKAGES})
-#install(TARGETS mapscript DESTINATION ${PYTHON_SITE_PACKAGES})
+install(TARGETS ${SWIG_MODULE_pythonmapscript_REAL_NAME} DESTINATION ${PYTHON_SITE_PACKAGES})
+install(FILES ${CMAKE_CURRENT_BINARY_DIR}/mapscript.py DESTINATION ${PYTHON_SITE_PACKAGES})
--- a/mapscript/php/CMakeLists.txt 2016-01-08 12:58:37.234524377 +0000
+++ b/mapscript/php/CMakeLists.txt 2016-01-08 12:58:49.634643100 +0000
@@ -36,6 +36,3 @@
set_target_properties(php_mapscript PROPERTIES PREFIX "")
install(TARGETS php_mapscript DESTINATION ${PHP5_EXTENSION_DIR})
-
-#install(FILES ${CMAKE_CURRENT_BINARY_DIR}/mapscript.py DESTINATION ${PYTHON_SITE_PACKAGES})
-#install(TARGETS mapscript DESTINATION ${PYTHON_SITE_PACKAGES})