Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:kimi:telephony-to-merge
liblinphone
liblinphone.spec
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File liblinphone.spec of Package liblinphone
# # spec file for package liblinphone # # Copyright (c) 2023 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via https://bugs.opensuse.org/ # %define _buildshell /bin/bash %define ldaplibdir %{buildroot}/%{_libexecdir}/linphone #use_system_ldap set to 0 because liblinphone 5.x fails to build with system ldap %define use_system_ldap 0 %define static_ldap 1 %if !0%{?static_ldap} %define __provides_exclude ^(libldap\\.so.*|liblber\\.so.*)$ %define __requires_exclude ^(libldap\\.so.*|liblber\\.so.*)$ %endif %define sover 10 %if 0%{?suse_version} >= 1600 %bcond_with slp %else %bcond_without slp %endif Name: liblinphone Version: 5.2.98 Release: 0 Summary: Web Phone License: AGPL-3.0-or-later Group: Productivity/Telephony/SIP/Clients URL: https://linphone.org/technical-corner/liblinphone/ Source: https://gitlab.linphone.org/BC/public/liblinphone/-/archive/%{version}/%{name}-%{version}.tar.bz2 Source3: https://gitlab.linphone.org/BC/public/external/openldap/-/archive/bc/openldap-bc.tar.bz2 # PATCH-FIX-OPENSUSE linphone-fix-pkgconfig.patch sor.alexei@meowr.ru -- Install linphone.pc. Patch0: linphone-fix-pkgconfig.patch # PATCH-FEATURE-OPENSUSE linphone-build-readline.patch sor.alexei@meowr.ru -- Add the ability to compile with readline to the build system. Patch1: linphone-build-readline.patch # PATCH-FIX-UPSTREAM Patch2: reproducible.patch # PATCH-FIX-OPENSUSE linphone-link-soci-sqlite3.patch -- force linking to libsoci_sqlite3 so that RPM finds the requirement boo#1140595 -- code@bnavigator.de Patch3: linphone-link-soci-sqlite3.patch # PATCH-FIX-OPENSUSE linphone-build-jsoncpp.patch -- use pkgconfig to find jsoncpp and link against jsoncpp, not jsoncpp_object Patch4: linphone-build-jsoncpp.patch Patch5: set_current_version.patch BuildRequires: cmake BuildRequires: doxygen BuildRequires: fdupes BuildRequires: gcc-c++ BuildRequires: graphviz BuildRequires: jsoncpp-devel BuildRequires: libeXosip2-devel %if 0%{?suse_version} BuildRequires: libgsm-devel %else BuildRequires: gsm-devel %endif BuildRequires: lime-devel >= %{version} BuildRequires: pkgconfig BuildRequires: python3 BuildRequires: python3-pystache BuildRequires: python3-six %if 0%{?suse_version} BuildRequires: python3-xml %endif BuildRequires: readline-devel %if 0%{?suse_version} BuildRequires: sgmltool %else BuildRequires: linuxdoc-tools %endif BuildRequires: soci-devel BuildRequires: soci-sqlite3-devel BuildRequires: xsd BuildRequires: pkgconfig(alsa) BuildRequires: pkgconfig(bctoolbox) >= %{version} BuildRequires: pkgconfig(belcard) >= 4.5.0 BuildRequires: pkgconfig(belle-sip) >= %{version} BuildRequires: pkgconfig(libavcodec) >= 51.0.0 BuildRequires: pkgconfig(libbzrtp) >= %{version} BuildRequires: pkgconfig(libosip2) BuildRequires: pkgconfig(libsasl2) BuildRequires: pkgconfig(libswscale) >= 0.7.0 BuildRequires: pkgconfig(libturbojpeg) BuildRequires: pkgconfig(libudev) BuildRequires: pkgconfig(libupnp) BuildRequires: pkgconfig(libv4l2) >= 0.8.4 BuildRequires: pkgconfig(libxml-2.0) BuildRequires: pkgconfig(mediastreamer) >= %{version} BuildRequires: pkgconfig(opus) BuildRequires: pkgconfig(ortp) >= %{version} BuildRequires: pkgconfig(speex) >= 1.1.6 BuildRequires: pkgconfig(sqlite3) BuildRequires: pkgconfig(xerces-c) BuildRequires: pkgconfig(zxing) %if 0%{?use_system_ldap} %if 0%{?suse_version} BuildRequires: openldap2-devel %else BuildRequires: openldap-devel %endif %else %if 0%{?suse_version} BuildRequires: db-devel %else BuildRequires: libdb-devel %endif %if %{with slp} BuildRequires: openslp-devel %endif %endif %if 0%{?fedora} BuildRequires: pkgconfig(openssl) %endif BuildRequires: chrpath %description Linphone is a Web phone with a Qt interface. It lets you make two-party calls over IP networks such as the Internet. It uses the IETF protocols SIP (Session Initiation Protocol) and RTP (Realtime TransporT Protocol) to make calls, so it should be able to communicate with other SIP-based Web phones. With several codecs available, it can be used with high speed connections as well as 28k modems. %package -n linphone-cli Summary: Web Phone Command Line Interface Group: Productivity/Telephony/SIP/Clients Requires: %{name}-data = %{version} %description -n linphone-cli Linphone is a Web phone with a Qt interface. It lets you make two-party calls over IP networks such as the Internet. It uses the IETF protocols SIP (Session Initiation Protocol) and RTP (Realtime TransporT Protocol) to make calls, so it should be able to communicate with other SIP-based Web phones. With several codecs available, it can be used with high speed connections as well as 28k modems. This package contains the command line interface. %package -n liblinphone%{sover} Summary: Web Phone library Group: System/Libraries %description -n liblinphone%{sover} Linphone is a Web phone with a Qt interface. It lets you make two-party calls over IP networks such as the Internet. It uses the IETF protocols SIP (Session Initiation Protocol) and RTP (Realtime TransporT Protocol) to make calls, so it should be able to communicate with other SIP-based Web phones. With several codecs available, it can be used with high speed connections as well as 28k modems. This package contains a library. %package -n liblinphone++%{sover} Summary: Web Phone C++ library Group: System/Libraries %description -n liblinphone++%{sover} Linphone is a Web phone with a Qt interface. It lets you make two-party calls over IP networks such as the Internet. It uses the IETF protocols SIP (Session Initiation Protocol) and RTP (Realtime TransporT Protocol) to make calls, so it should be able to communicate with other SIP-based Web phones. With several codecs available, it can be used with high speed connections as well as 28k modems. This package contains a C++ library. %package data Summary: Web Phone data files Group: Productivity/Telephony/SIP/Clients BuildArch: noarch %description data Linphone is a Web phone with a Qt interface. It lets you make two-party calls over IP networks such as the Internet. It uses the IETF protocols SIP (Session Initiation Protocol) and RTP (Realtime TransporT Protocol) to make calls, so it should be able to communicate with other SIP-based Web phones. With several codecs available, it can be used with high speed connections as well as 28k modems. This package contains data files such as sounds. %package devel Summary: Web Phone Development files Group: Development/Languages/C and C++ Requires: glibc-devel Requires: liblinphone%{sover} = %{version} Requires: liblinphone++%{sover} = %{version} Requires: %{name}-data = %{version} Requires: libeXosip2-devel Requires: libosip2-devel Requires: soci-devel Requires: soci-sqlite3-devel Requires: pkgconfig(alsa) Requires: pkgconfig(glib-2.0) Requires: pkgconfig(libavcodec) >= 51.0.0 Requires: pkgconfig(libswscale) >= 0.7.0 Requires: pkgconfig(speex) %description devel Linphone is a Web phone with a Qt interface. It lets you make two-party calls over IP networks such as the Internet. It uses the IETF protocols SIP (Session Initiation Protocol) and RTP (Realtime TransporT Protocol) to make calls, so it should be able to communicate with other SIP-based Web phones. With several codecs available, it can be used with high speed connections as well as 28k modems. %prep %autosetup -p1 %if 0%{?fedora} # patch deprecated python open mode sed -i "s|mode='rU'|mode='r'|" wrappers/cpp/genwrapper.py # patch ssl sasl - extends linphone-build-jsoncpp.patch sed -i "s|jsoncpp)|jsoncpp ssl sasl2)|g" src/CMakeLists.txt sed -i "s|bctoolbox|bctoolbox ssl sasl2|g" src/CMakeLists.txt sed -i "s|jsoncpp)|jsoncpp ssl sasl2)|g" tester/CMakeLists.txt %endif %build %if !0%{?use_system_ldap} #START build belledonne's libldap mkdir aux tar -xf %{SOURCE3} -C aux cd aux/openldap-bc LDFLAGS="-Wl,-rpath,%ldaplibdir" ./configure \ %if 0%{?static_ldap} --enable-static=yes \ --enable-shared=no \ --with-pic \ %else --enable-static=no \ %endif --enable-slapd=no \ --enable-wrappers=no \ --enable-spasswd \ --with-tls=openssl \ --with-cyrus-sasl \ --enable-crypt \ --enable-ipv6=yes \ --enable-rewrite \ %if %{with slp} --enable-slp \ %endif --enable-lmpasswd \ --with-yielding-select \ --prefix="$PWD/.." \ --libdir=%{ldaplibdir} make depend %make_build # do a preliminary install, because libldap is needed to build liblinphone make install cd ../.. #END build belledonne's libldap #find and use belledonne's libldap sed -i "/OPENLDAP_INCLUDE_DIRS/,/LDAP_LIB/s@\${CMAKE_INSTALL_PREFIX}@$PWD/aux@;s@\${CMAKE_INSTALL_PREFIX}@%{ldaplibdir}@;s@include/openldap@include@" cmake/FindOpenLDAP.cmake %endif %cmake \ -DPYTHON_EXECUTABLE="%{_bindir}/python3" \ -DENABLE_CXX_WRAPPER=ON \ %if !0%{?use_system_ldap} %if 0%{?suse_version} -DOPENLDAP_INCLUDE_DIRS=$PWD/../aux/include \ %else -DOPENLDAP_INCLUDE_DIRS=$PWD/aux/include \ -DCMAKE_INSTALL_LIBDIR=lib64 \ %endif %if 0%{?static_ldap} -DLDAP_LIB=%{ldaplibdir}/libldap.a \ %else -DLDAP_LIB=%{ldaplibdir}/libldap.so \ %endif -DCMAKE_SHARED_LINKER_FLAGS="-Wl,-rpath,%{ldaplibdir}" \ %endif -DENABLE_DOC=ON \ -DCMAKE_BUILD_TYPE=Release \ -DENABLE_ROOTCA_DOWNLOAD=OFF \ -DENABLE_ZRTP=ON \ -DENABLE_LDAP=ON \ -DENABLE_TOOLS=OFF \ -DENABLE_STRICT=OFF \ -DENABLE_STATIC=OFF \ -DENABLE_FLEXIAPI=OFF \ %if 0%{?suse_version} > 1500 -DENABLE_QRCODE=OFF \ %endif -DCMAKE_LINK_WHAT_YOU_USE=ON %cmake_build %install %if !0%{?use_system_ldap} #START reinstall belledonne's libldap cd aux/openldap-bc make install cd ../.. cp aux/openldap-bc/LICENSE LICENSE.openldap #END reinstall belledonne's libldap %endif %cmake_install %if !0%{?use_system_ldap} %if !0%{?static_ldap} #remove unnecessary files rm %{ldaplibdir}/*.{la,so} #fix rpath in openldap libs and make them executable find %{ldaplibdir} -type f -exec chrpath -r %{_libexecdir}/linphone {} + -exec chmod a+x {} + #fix rpath in liblinphone find %{buildroot}/%{_libdir} -type f -name "liblinphone*" -exec chrpath -r %{_libexecdir}/linphone {} + # Remove openldap pkgconfig files. rm -r %{ldaplibdir}/pkgconfig %else rm -r %{ldaplibdir} %endif %endif chrpath -d %{buildroot}/%{_libdir}/liblinphone.so.%{sover}* %{buildroot}/%{_libdir}/liblinphone++.so.%{sover}* chrpath -d %{buildroot}/%{_bindir}/{linphone-daemon-pipetest,linphone-daemon,groupchat_benchmark,linphonec,linphonecsh,liblinphone_tester} %if !0%{?use_system_ldap} && 0%{?fedora} # ldaplibdir will remain in lib, disable check-buildroot for Fedora export QA_SKIP_BUILD_ROOT=0 %endif %fdupes %{buildroot}/%{_datadir}/ %post -n liblinphone%{sover} -p /sbin/ldconfig %postun -n liblinphone%{sover} -p /sbin/ldconfig %post -n liblinphone++%{sover} -p /sbin/ldconfig %postun -n liblinphone++%{sover} -p /sbin/ldconfig %files -n linphone-cli %{_bindir}/linphonec* %{_bindir}/linphone-daemon* %files -n liblinphone%{sover} %{_libdir}/liblinphone.so.%{sover}* %if !0%{?use_system_ldap} %if !0%{?static_ldap} %{_libexecdir}/linphone/ %endif %endif %files -n liblinphone++%{sover} %{_libdir}/liblinphone++.so.%{sover}* %files -n liblinphone-data %license LICENSE.txt %if !0%{?use_system_ldap} %license LICENSE.openldap %endif %doc CHANGELOG.md README.md %{_datadir}/linphone/ %{_datadir}/sounds/linphone/ %{_datadir}/belr/grammars/*_grammar %files -n liblinphone-devel %{_includedir}/linphone*/ %{_bindir}/liblinphone_tester %{_bindir}/groupchat_benchmark %{_libdir}/liblinphone.so %{_libdir}/liblinphone++.so %{_datadir}/liblinphone_tester/ %{_libdir}/pkgconfig/linphone.pc %{_datadir}/Linphone/ %{_datadir}/LinphoneCxx/ %{_datadir}/doc/liblinphone-%{version}/ %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