重磅SRS 5.0正式支持Windows平台和安装引导程式
SRS 支持Windows
SRS 5.0.89 正式支持Windows,基于Cygwin64平台,支持代码编译,以及流水线,每个5.0的版本都会提供安装包。
编译代码
如果你需要自己从代码编译Windows版本的SRS,请先安装Cygwin64[1]。
另外,还需要安装工具gcc-g make automake patch pkg-config tcl cmake,可以参考流水线说明[2]。
安装好环境后,在Cygwin终端中执行命令:
-
git checkout develop
-
./configure
-
make
这样就可以编译出Windows版本的SRS了,可执行文件在./objs/srs.exe,其他使用说明参考Getting Started[3]。
从二进制文件安装
从5.0.89之后,SRS 5.0每个版本release[4],都会附带Windows的安装包。你可以下载后,快速安装和使用SRS。
下面是一些安装包的链接,注意你应该用最新版本,而不是使用某个固定版本release[5]:
• 最新版本下载[6]
• SRS-Windows-x86_64-5.0.89-setup.exe[7]
• SRS-Windows-x86_64-5.0.19-setup.exe[8]
Note: SRS 5.0.89 之后,使用流水线构建Windows安装包,GitHub Actions自动生成。
安装后,使用管理员权限启动SRS:
使用FFmpeg或OBS推流到SRS:
ffmpeg -re -i ~/srs/doc/source.flv -c copy -f flv rtmp://win11/live/livestream
使用VLC或srs-player[9]播放流:
基本上SRS现有的功能都能用,比如RTMP, HTTP-FLV, HLS, WebRTC, HTTP-API, Prometheus Exporter等等。
从NSIS打包
如果你需要自己修改代码并打包,可以使用NSIS[10],在Cygwin终端中执行命令:
-
"/cygdrive/c/Program Files (x86)/NSIS/makensis.exe" \
-
/DSRS_VERSION=$(./objs/srs -v 2>&1) \
-
/DCYGWIN_DIR="C:\cygwin64" \
-
packaging/nsis/srs.nsi
已知问题
• Cygwin: Build with SRT is ok, but crash when running. #3251[11]
• Cygwin: Support address sanitizer for windows. #3252[12]
• Cygwin: ST stuck when working in multiple threads mode. #3253[13]
• Cygwin: Support iocp and windows native build. #3256[14]
• Cygwin: Build srtp with openssl fail for no srtp_aes_icm_ctx_t #3254[15]
链接
ST supports windows: https://github.com/ossrs/state-threads/issues/20
Commits about SRS Windows: https://github.com/ossrs/srs-windows/issues/2
Windows docker also works for SRS, however, srs.exe is more popular for windows developers.
引用链接
[1] Cygwin64: https://cygwin.com/install.html
[2] 说明: https://github.com/cygwin/cygwin-install-action#parameters
[3] Getting Started: ./getting-started.md
[4] release: https://github.com/ossrs/srs/releases
[5] release: https://github.com/ossrs/srs/releases
[6] 最新版本下载: https://github.com/ossrs/srs/releases
[7] SRS-Windows-x86_64-5.0.89-setup.exe: https://github.com/ossrs/srs/releases/tag/v5.0.89
[8] SRS-Windows-x86_64-5.0.19-setup.exe: https://github.com/ossrs/srs/releases/tag/v5.0.19
[9] srs-player: http://win11:8080/
[10] NSIS: https://nsis.sourceforge.io/Download
[11] Cygwin: Build with SRT is ok, but crash when running. #3251: https://github.com/ossrs/srs/issues/3251
[12] Cygwin: Support address sanitizer for windows. #3252: https://github.com/ossrs/srs/issues/3252 [13] Cygwin: ST stuck when working in multiple threads mode. #3253: https://github.com/ossrs/srs/issues/3253
[14] Cygwin: Support iocp and windows native build. #3256: https://github.com/ossrs/srs/issues/3256 [15] Cygwin: Build srtp with openssl fail for no srtp_aes_icm_ctx_t #3254: https://github.com/ossrs/srs/issues/3254
作者:赵文杰
原文链接: https://mp.weixin.qq.com/s?__biz=MzA4NTQ3MzQ5OA==&mid=2649005647&idx=1&sn=0bceba60d5270479bab12b1d5ccc1d54&chksm=87c75ffab0b0d6ec2d428856c8761a5ebee799a8c5205d521c538195dbefcc9b673266e8182f&mpshare=1&scene=23&srcid=021792kH971FSrTrUPKExYXD&sharer_sharetime=1676614148369&sharer_shareid=a96e9b09ebf11547090dd99009e597bb#rd
这篇好文章是转载于:学新通技术网
- 版权申明: 本站部分内容来自互联网,仅供学习及演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,请提供相关证据及您的身份证明,我们将在收到邮件后48小时内删除。
- 本站站名: 学新通技术网
- 本文地址: /boutique/detail/tanhfeagke
-
photoshop保存的图片太大微信发不了怎么办
PHP中文网 06-15 -
Android 11 保存文件到外部存储,并分享文件
Luke 10-12 -
《学习通》视频自动暂停处理方法
HelloWorld317 07-05 -
word里面弄一个表格后上面的标题会跑到下面怎么办
PHP中文网 06-20 -
photoshop扩展功能面板显示灰色怎么办
PHP中文网 06-14 -
微信公众号没有声音提示怎么办
PHP中文网 03-31 -
excel下划线不显示怎么办
PHP中文网 06-23 -
excel打印预览压线压字怎么办
PHP中文网 06-22 -
怎样阻止微信小程序自动打开
PHP中文网 06-13 -
TikTok加速器哪个好免费的TK加速器推荐
TK小达人 10-01