Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:maw
thrift
thrift.spec
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File thrift.spec of Package thrift
# # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not use this file except in compliance # with the License. You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, # software distributed under the License is distributed on an # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY # KIND, either express or implied. See the License for the # specific language governing permissions and limitations # under the License. # %define without_java 1 %define without_erlang 1 # TODO(dreiss): Have a Python build with and without the extension. %{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} %{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} # TODO(dreiss): Where is this supposed to go? %{!?thrift_erlang_root: %define thrift_erlang_root /opt/thrift-erl} BuildRequires: bison BuildRequires: boost-devel BuildRequires: flex BuildRequires: gcc >= 3.4.6 BuildRequires: gcc-c++ %if %{!?without_python: 1} BuildRequires: python-devel %endif Name: thrift License: Apache License v2.0 Group: Development Summary: RPC and serialization framework Source0: %{name}-%{version}-incubating.tar.gz Version: 0.2.0 Release: 1 URL: http://developers.facebook.com/thrift BuildRoot: %{_tmppath}/%{name}-%{version}-build %description Thrift is a software framework for scalable cross-language services development. It combines a powerful software stack with a code generation engine to build services that work efficiently and seamlessly between C++, Java, C#, Python, Ruby, Perl, PHP, Objective C/Cocoa, Smalltalk, Erlang, Objective Caml, and Haskell. %package -n libthrift0 Summary: Thrift C++ library Group: Libraries %description -n libthrift0 C++ libraries for Thrift. %package lib-cpp-devel Summary: Thrift C++ library development files Group: Development/Libraries/C and C++ Requires: %{name} = %{version}-%{release} Requires: boost-devel Requires: libthrift0 %if %{!?without_libevent: 1} Requires: libevent-devel >= 1.2 %endif %if %{!?without_zlib: 1} Requires: zlib-devel %endif %description lib-cpp-devel C++ static libraries and headers for Thrift. %if %{!?without_python: 1} %package -n python-thrift Summary: Thrift Python library Group: Libraries %description -n python-thrift Python libraries for Thrift. %endif %prep %setup -q -n %{name}-%{version} %build # TODO(dreiss): Implement a single --without-build-kludges. # I'm not interested in packaging perl right now either export CFLAGS="-fno-strict-aliasing" export CCFLAGS="$CFLAGS" export CPPFLAGS="$CFLAGS" %configure \ %{?without_libevent: --without-libevent } \ %{?without_zlib: --without-zlib } \ --without-java \ --without-csharp \ --without-py \ --without-erlang \ --without-perl make %if %{!?without_python: 1} cd lib/py CFLAGS="%{optflags}" %{__python} setup.py build cd ../.. %endif %install %makeinstall rm $RPM_BUILD_ROOT/%{_libdir}/*.*a %if %{!?without_python: 1} cd lib/py %{__python} setup.py install --skip-build --root $RPM_BUILD_ROOT --prefix=%{_prefix} --record-rpm ../../python-%{name}.files.1 cd ../.. echo '%%defattr(-, root, root)' > python-%{name}.files cat python-%{name}.files.1 >> python-%{name}.files %endif %clean ### rm -rf $RPM_BUILD_ROOT %post -n libthrift0 -p /sbin/ldconfig %postun -n libthrift0 -p /sbin/ldconfig %files %defattr(-,root,root) %{_bindir}/thrift %files -n libthrift0 %defattr(-,root,root) %{_libdir}/libthrift*.so.* %files lib-cpp-devel %defattr(-,root,root) %{_includedir}/thrift/ #%{_libdir}/libthrift*.*a %{_libdir}/libthrift*.so %{_libdir}/pkgconfig/thrift*.pc %if %{!?without_python: 1} %files -n python-thrift -f python-thrift.files %endif # TODO(dreiss): Can these be moved into the individual packages? ##%if %{!?without_java: 1} ##BuildRequires: java-devel >= 0:1.5.0 ##BuildRequires: ant >= 0:1.6.5 ##%endif ##%if %{!?without_erlang: 1} ##BuildRequires: erlang ##%endif # %if %{!?without_erlang: 1} # %package lib-erlang # Summary: Thrift Python library # Group: Libraries # Requires: erlang # %description lib-erlang # Erlang libraries for Thrift. # %files lib-erlang # %defattr(-,root,root) # %{thrift_erlang_root} # %endif # %if %{!?without_java: 1} # cd lib/java # %ant # cd ../.. # %endif # %if %{!?without_erlang: 1} # cd lib/erl # make # cd ../.. # %endif # %if %{!?without_java: 1} # %package lib-java # Summary: Thrift Java library # Group: Libraries # Requires: java >= 0:1.5.0 # %description lib-java # Java libraries for Thrift. # %files lib-java # %defattr(-,root,root) # %{_javadir}/* # %endif # %if %{!?without_java: 1} # mkdir -p $RPM_BUILD_ROOT%{_javadir} # cp -p lib/java/*.jar $RPM_BUILD_ROOT%{_javadir} # %endif # %if %{!?without_erlang: 1} # mkdir -p ${RPM_BUILD_ROOT}%{thrift_erlang_root} # cp -r lib/erl/ebin ${RPM_BUILD_ROOT}%{thrift_erlang_root} # %endif %changelog
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor