FreeBSD Bugzilla – Attachment 222255 Details for
Bug 253334
[new port] net-im/tg_owt: webrtc library used by telegram-desktop
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
patch for the new port
tg_owt-20210207.txt (text/plain), 13.20 KB, created by
Henry Hu
on 2021-02-08 02:32:53 UTC
(
hide
)
Description:
patch for the new port
Filename:
MIME Type:
Creator:
Henry Hu
Created:
2021-02-08 02:32:53 UTC
Size:
13.20 KB
patch
obsolete
>diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/Makefile ./Makefile >--- /usr/ports/net-im/tg_owt/Makefile 1969-12-31 19:00:00.000000000 -0500 >+++ ./Makefile 2021-02-07 21:21:34.767401000 -0500 >@@ -0,0 +1,59 @@ >+# Created by: Henry Hu <henry.hu.sh@gmail.com> >+# $FreeBSD$ >+ >+PORTNAME= tg_owt >+PORTVERSION= 0.0.20210207 >+CATEGORIES= net-im >+MASTER_SITES= https://chromium.googlesource.com/webm/libvpx.git/+archive/:libvpx \ >+ https://chromium.googlesource.com/libyuv/libyuv.git/+archive/:libyuv >+DISTFILES= ${LIBYUV_TAGNAME}.tar.gz:libvpx \ >+ ${LIBVPX_TAGNAME}.tar.gz:libyuv >+EXTRACT_ONLY= ${DISTFILE_DEFAULT} >+ >+MAINTAINER= henry.hu.sh@gmail.com >+COMMENT= Webrtc library used by telegram-desktop >+ >+LICENSE= BSD3CLAUSE >+LICENSE_FILE= ${WRKSRC}/LICENSE >+ >+BUILD_DEPENDS= alsa-lib>0:audio/alsa-lib \ >+ pulseaudio>0:audio/pulseaudio \ >+ v4l_compat>0:multimedia/v4l_compat \ >+ yasm:devel/yasm >+LIB_DEPENDS= libavformat.so:multimedia/ffmpeg \ >+ libjpeg.so:graphics/jpeg-turbo \ >+ libusrsctp.so:net/libusrsctp \ >+ libopus.so:audio/opus >+ >+USES= cmake pkgconfig >+USE_GITHUB= yes >+GH_ACCOUNT= desktop-app >+GH_PROJECT= tg_owt >+GH_TAGNAME= a198773 >+ >+# libvpx version in src/third_party/libvpx/source/libvpx >+# libyuv verison in src/third_party/libyuv >+LIBYUV_TAGNAME= ad89006 >+LIBVPX_TAGNAME= 5b63f0f >+ >+# Disable DCHECKs, otherwise video calls will crash. >+CXXFLAGS+= -DNDEBUG >+ >+CMAKE_OFF= BUILD_SHARED_LIBS >+ >+post-extract: >+ # Extract Git submodules >+ (cd ${WRKSRC}/src/third_party/libyuv && \ >+ ${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} \ >+ ${_DISTDIR}${LIBYUV_TAGNAME}.tar.gz ${EXTRACT_AFTER_ARGS}) >+ (cd ${WRKSRC}/src/third_party/libvpx/source/libvpx && \ >+ ${EXTRACT_CMD} ${EXTRACT_BEFORE_ARGS} \ >+ ${_DISTDIR}${LIBVPX_TAGNAME}.tar.gz ${EXTRACT_AFTER_ARGS}) >+ >+do-install: >+ ${INSTALL_DATA} ${BUILD_WRKSRC}/libtg_owt.a ${STAGEDIR}${PREFIX}/lib >+ ${MKDIR} ${STAGEDIR}${PREFIX}/lib/cmake/tg_owt >+ ${INSTALL_DATA} ${BUILD_WRKSRC}/tg_owtConfig.cmake ${STAGEDIR}${PREFIX}/lib/cmake/tg_owt >+ ${INSTALL_DATA} ${BUILD_WRKSRC}/tg_owtTargets.cmake ${STAGEDIR}${PREFIX}/lib/cmake/tg_owt >+ >+.include <bsd.port.mk> >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/distinfo ./distinfo >--- /usr/ports/net-im/tg_owt/distinfo 1969-12-31 19:00:00.000000000 -0500 >+++ ./distinfo 2021-02-07 21:21:57.677127000 -0500 >@@ -0,0 +1,7 @@ >+TIMESTAMP = 1612750917 >+SHA256 (ad89006.tar.gz) = 1b4c4b781c89640c65ce67cb04e0acacd3769630eae740457ccfb1b53367a873 >+SIZE (ad89006.tar.gz) = 473828 >+SHA256 (5b63f0f.tar.gz) = 803ef30f9f3ff7186c1c277808b9b47a2baf79812934ed98629689aee2484c4c >+SIZE (5b63f0f.tar.gz) = 5324151 >+SHA256 (desktop-app-tg_owt-0.0.20210207-a198773_GH0.tar.gz) = 999ed345a80e817d82eddda88acc6d5f24dd558debe6434111d0e5ff9bd9fb1f >+SIZE (desktop-app-tg_owt-0.0.20210207-a198773_GH0.tar.gz) = 16153730 >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/files/patch-CMakeLists.txt ./files/patch-CMakeLists.txt >--- /usr/ports/net-im/tg_owt/files/patch-CMakeLists.txt 1969-12-31 19:00:00.000000000 -0500 >+++ ./files/patch-CMakeLists.txt 2021-02-07 21:24:18.736076000 -0500 >@@ -0,0 +1,46 @@ >+--- CMakeLists.txt.orig 2021-02-03 11:42:41 UTC >++++ CMakeLists.txt >+@@ -54,7 +54,6 @@ include(cmake/libopenh264.cmake) >+ include(cmake/libpffft.cmake) >+ include(cmake/librnnoise.cmake) >+ include(cmake/libsrtp.cmake) >+-include(cmake/libusrsctp.cmake) >+ include(cmake/libvpx.cmake) >+ include(cmake/libwebrtcbuild.cmake) >+ include(cmake/libyuv.cmake) >+@@ -88,7 +87,6 @@ if (is_x86 OR is_x64) >+ tg_owt::libpffft >+ tg_owt::librnnoise >+ tg_owt::libsrtp >+- tg_owt::libusrsctp >+ tg_owt::libvpx >+ tg_owt::libvpx_mmx >+ tg_owt::libvpx_sse2 >+@@ -137,6 +135,7 @@ endif() >+ link_openssl(tg_owt) >+ link_ffmpeg(tg_owt) >+ link_opus(tg_owt) >++link_usrsctp(tg_owt) >+ >+ if (UNIX AND NOT APPLE) >+ link_libalsa(tg_owt) >+@@ -145,6 +144,11 @@ if (UNIX AND NOT APPLE) >+ link_x11(tg_owt) >+ endif() >+ >++target_include_directories(tg_owt BEFORE PRIVATE $<TARGET_PROPERTY:tg_owt::libabsl,INTERFACE_INCLUDE_DIRECTORIES>) >++target_include_directories(tg_owt BEFORE PRIVATE $<TARGET_PROPERTY:tg_owt::libvpx,INTERFACE_INCLUDE_DIRECTORIES>) >++target_include_directories(tg_owt BEFORE PRIVATE $<TARGET_PROPERTY:tg_owt::libyuv,INTERFACE_INCLUDE_DIRECTORIES>) >++target_include_directories(tg_owt BEFORE PRIVATE "src") >++ >+ function(add_sublibrary postfix) >+ add_library(tg_owt_${postfix} OBJECT) >+ init_feature_target(tg_owt_${postfix} ${postfix}) >+@@ -2188,7 +2192,6 @@ set(export_targets >+ libpffft >+ librnnoise >+ libsrtp >+- libusrsctp >+ libvpx >+ ${vpx_export} >+ libwebrtcbuild >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/files/patch-cmake_external.cmake ./files/patch-cmake_external.cmake >--- /usr/ports/net-im/tg_owt/files/patch-cmake_external.cmake 1969-12-31 19:00:00.000000000 -0500 >+++ ./files/patch-cmake_external.cmake 2021-02-07 21:24:18.737128000 -0500 >@@ -0,0 +1,16 @@ >+--- cmake/external.cmake.orig 2021-02-03 11:42:41 UTC >++++ cmake/external.cmake >+@@ -141,3 +141,13 @@ function(link_x11 target_name) >+ target_link_libraries(${target_name} PRIVATE ${X11_Xtst_LIB}) >+ endif() >+ endfunction() >++ >++# usrsctp >++function(link_usrsctp target_name) >++ if (TG_OWT_PACKAGED_BUILD) >++ find_package(PkgConfig REQUIRED) >++ pkg_check_modules(USRSCTP REQUIRED usrsctp) >++ target_include_directories(${target_name} PRIVATE ${USRSCTP_INCLUDE_DIRS}) >++ target_link_libraries(${target_name} PRIVATE ${USRSCTP_LINK_LIBRARIES}) >++ endif() >++endfunction() >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/files/patch-cmake_libevent.cmake ./files/patch-cmake_libevent.cmake >--- /usr/ports/net-im/tg_owt/files/patch-cmake_libevent.cmake 1969-12-31 19:00:00.000000000 -0500 >+++ ./files/patch-cmake_libevent.cmake 2021-02-07 21:24:18.738171000 -0500 >@@ -0,0 +1,26 @@ >+--- cmake/libevent.cmake.orig 2021-02-03 11:42:41 UTC >++++ cmake/libevent.cmake >+@@ -17,14 +17,13 @@ if (APPLE) >+ else() >+ target_include_directories(libevent >+ PRIVATE >+- ${libevent_loc}/linux >++ ${libevent_loc}/freebsd >+ ) >+ endif() >+ >+ nice_target_sources(libevent ${libevent_loc} >+ PRIVATE >+ buffer.c >+- epoll.c >+ evbuffer.c >+ evdns.c >+ event.c >+@@ -32,6 +31,7 @@ PRIVATE >+ evrpc.c >+ evutil.c >+ http.c >++ kqueue.c >+ log.c >+ poll.c >+ select.c >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/files/patch-cmake_libyuv.cmake ./files/patch-cmake_libyuv.cmake >--- /usr/ports/net-im/tg_owt/files/patch-cmake_libyuv.cmake 1969-12-31 19:00:00.000000000 -0500 >+++ ./files/patch-cmake_libyuv.cmake 2021-02-07 21:24:18.739326000 -0500 >@@ -0,0 +1,11 @@ >+--- cmake/libyuv.cmake.orig 2021-02-03 11:42:41 UTC >++++ cmake/libyuv.cmake >+@@ -126,7 +126,7 @@ else() >+ endif() >+ >+ target_include_directories(libyuv >+-PUBLIC >++BEFORE PUBLIC >+ $<BUILD_INTERFACE:${libyuv_loc}/include> >+ $<INSTALL_INTERFACE:${webrtc_includedir}/third_party/libyuv/include> >+ ) >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/files/patch-src_rtc__base_byte__order.h ./files/patch-src_rtc__base_byte__order.h >--- /usr/ports/net-im/tg_owt/files/patch-src_rtc__base_byte__order.h 1969-12-31 19:00:00.000000000 -0500 >+++ ./files/patch-src_rtc__base_byte__order.h 2021-02-07 21:24:18.740554000 -0500 >@@ -0,0 +1,11 @@ >+--- src/rtc_base/byte_order.h.orig 2021-02-03 11:42:41 UTC >++++ src/rtc_base/byte_order.h >+@@ -89,7 +89,7 @@ >+ #endif // defined(WEBRTC_ARCH_LITTLE_ENDIAN) >+ >+ #elif defined(WEBRTC_POSIX) >+-#include <endian.h> >++#include <sys/endian.h> >+ #else >+ #error "Missing byte order functions for this arch." >+ #endif // defined(WEBRTC_MAC) >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/files/patch-src_rtc__base_ip__address.cc ./files/patch-src_rtc__base_ip__address.cc >--- /usr/ports/net-im/tg_owt/files/patch-src_rtc__base_ip__address.cc 1969-12-31 19:00:00.000000000 -0500 >+++ ./files/patch-src_rtc__base_ip__address.cc 2021-02-07 21:24:18.741636000 -0500 >@@ -0,0 +1,10 @@ >+--- src/rtc_base/ip_address.cc.orig 2021-02-03 11:42:41 UTC >++++ src/rtc_base/ip_address.cc >+@@ -15,6 +15,7 @@ >+ #include <netinet/in_systm.h> >+ #endif >+ #ifndef __native_client__ >++#include <sys/types.h> >+ #include <netinet/ip.h> >+ #endif >+ #include <netdb.h> >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/files/patch-src_rtc__base_physical__socket__server.cc ./files/patch-src_rtc__base_physical__socket__server.cc >--- /usr/ports/net-im/tg_owt/files/patch-src_rtc__base_physical__socket__server.cc 1969-12-31 19:00:00.000000000 -0500 >+++ ./files/patch-src_rtc__base_physical__socket__server.cc 2021-02-07 21:24:18.742689000 -0500 >@@ -0,0 +1,29 @@ >+--- src/rtc_base/physical_socket_server.cc.orig 2021-02-03 11:42:41 UTC >++++ src/rtc_base/physical_socket_server.cc >+@@ -50,6 +50,8 @@ >+ #include "rtc_base/null_socket_server.h" >+ #include "rtc_base/time_utils.h" >+ >++#undef WEBRTC_LINUX >++ >+ #if defined(WEBRTC_LINUX) >+ #include <linux/sockios.h> >+ #endif >+@@ -69,7 +71,7 @@ typedef void* SockOptArg; >+ >+ #endif // WEBRTC_POSIX >+ >+-#if defined(WEBRTC_POSIX) && !defined(WEBRTC_MAC) && !defined(__native_client__) >++#if defined(WEBRTC_POSIX) && !defined(WEBRTC_MAC) && !defined(__native_client__) && !defined(__FreeBSD__) >+ >+ int64_t GetSocketRecvTimestamp(int socket) { >+ struct timeval tv_ioctl; >+@@ -571,7 +573,7 @@ int PhysicalSocket::TranslateOption(Option opt, int* s >+ *slevel = IPPROTO_IP; >+ *sopt = IP_DONTFRAGMENT; >+ break; >+-#elif defined(WEBRTC_MAC) || defined(BSD) || defined(__native_client__) >++#elif defined(WEBRTC_MAC) || defined(BSD) || defined(__native_client__) || defined(__FreeBSD__) >+ RTC_LOG(LS_WARNING) << "Socket::OPT_DONTFRAGMENT not supported."; >+ return -1; >+ #elif defined(WEBRTC_POSIX) >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/files/patch-src_rtc__base_physical__socket__server.h ./files/patch-src_rtc__base_physical__socket__server.h >--- /usr/ports/net-im/tg_owt/files/patch-src_rtc__base_physical__socket__server.h 1969-12-31 19:00:00.000000000 -0500 >+++ ./files/patch-src_rtc__base_physical__socket__server.h 2021-02-07 21:24:18.743795000 -0500 >@@ -0,0 +1,11 @@ >+--- src/rtc_base/physical_socket_server.h.orig 2021-02-03 11:42:41 UTC >++++ src/rtc_base/physical_socket_server.h >+@@ -12,8 +12,6 @@ >+ #define RTC_BASE_PHYSICAL_SOCKET_SERVER_H_ >+ >+ #if defined(WEBRTC_POSIX) && defined(WEBRTC_LINUX) >+-#include <sys/epoll.h> >+-#define WEBRTC_USE_EPOLL 1 >+ #endif >+ >+ #include <array> >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/files/patch-src_rtc__base_platform__thread__types.cc ./files/patch-src_rtc__base_platform__thread__types.cc >--- /usr/ports/net-im/tg_owt/files/patch-src_rtc__base_platform__thread__types.cc 1969-12-31 19:00:00.000000000 -0500 >+++ ./files/patch-src_rtc__base_platform__thread__types.cc 2021-02-07 21:24:18.744883000 -0500 >@@ -0,0 +1,43 @@ >+--- src/rtc_base/platform_thread_types.cc.orig 2021-02-03 11:42:41 UTC >++++ src/rtc_base/platform_thread_types.cc >+@@ -11,10 +11,14 @@ >+ #include "rtc_base/platform_thread_types.h" >+ >+ #if defined(WEBRTC_LINUX) >+-#include <sys/prctl.h> >+ #include <sys/syscall.h> >+ #endif >+ >++#ifdef __FreeBSD__ >++#include <sys/thr.h> >++#include <pthread_np.h> >++#endif >++ >+ #if defined(WEBRTC_WIN) >+ #include "rtc_base/arraysize.h" >+ >+@@ -38,7 +42,13 @@ PlatformThreadId CurrentThreadId() { >+ #elif defined(WEBRTC_FUCHSIA) >+ return zx_thread_self(); >+ #elif defined(WEBRTC_LINUX) >++#if defined(__FreeBSD__) >++ long id; >++ thr_self(&id); >++ return id; >++#else >+ return syscall(__NR_gettid); >++#endif >+ #elif defined(__EMSCRIPTEN__) >+ return static_cast<PlatformThreadId>(pthread_self()); >+ #else >+@@ -106,9 +116,7 @@ void SetCurrentThreadName(const char* name) { >+ } >+ #pragma warning(pop) >+ #elif defined(WEBRTC_LINUX) || defined(WEBRTC_ANDROID) >+- prctl(PR_SET_NAME, reinterpret_cast<unsigned long>(name)); // NOLINT >+-#elif defined(WEBRTC_MAC) || defined(WEBRTC_IOS) >+- pthread_setname_np(name); >++ pthread_set_name_np(pthread_self(), name); >+ #endif >+ } >+ >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/pkg-descr ./pkg-descr >--- /usr/ports/net-im/tg_owt/pkg-descr 1969-12-31 19:00:00.000000000 -0500 >+++ ./pkg-descr 2021-02-07 21:18:07.203623000 -0500 >@@ -0,0 +1,3 @@ >+WebRTC library used by telegram-desktop. >+ >+WWW: https://github.com/desktop-app/tg_owt >diff -ruN -x work -x sync-patch.sh -x gen-patch.sh -x update.md -x check-diff.py -x files.bak /usr/ports/net-im/tg_owt/pkg-plist ./pkg-plist >--- /usr/ports/net-im/tg_owt/pkg-plist 1969-12-31 19:00:00.000000000 -0500 >+++ ./pkg-plist 2020-10-26 23:23:42.768229000 -0400 >@@ -0,0 +1,3 @@ >+lib/cmake/tg_owt/tg_owtConfig.cmake >+lib/cmake/tg_owt/tg_owtTargets.cmake >+lib/libtg_owt.a
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 253334
:
222255
|
222256
|
222264
|
222265
|
222313