Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
尘离序散
obs-studio
提交
32690926
O
obs-studio
项目概览
尘离序散
/
obs-studio
与 Fork 源项目一致
从无法访问的项目Fork
通知
30
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
O
obs-studio
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
32690926
编写于
10月 15, 2019
作者:
C
Colin Edwards
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
CI: Use custom macdylibbundler for OSX deps
上级
7c08b3f9
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
112 addition
and
28 deletion
+112
-28
CI/before-deploy-osx.sh
CI/before-deploy-osx.sh
+8
-21
CI/install-dependencies-osx.sh
CI/install-dependencies-osx.sh
+1
-1
CI/install/osx/dylibBundler
CI/install/osx/dylibBundler
+0
-0
CI/install/osx/packageApp.sh
CI/install/osx/packageApp.sh
+66
-0
UI/platform-osx.mm
UI/platform-osx.mm
+6
-4
deps/obs-scripting/CMakeLists.txt
deps/obs-scripting/CMakeLists.txt
+5
-0
deps/obs-scripting/obs-scripting-lua.c
deps/obs-scripting/obs-scripting-lua.c
+26
-2
未找到文件。
CI/before-deploy-osx.sh
浏览文件 @
32690926
...
...
@@ -35,32 +35,17 @@ fi
#sudo python ../CI/install/osx/build_app.py --public-key ../CI/install/osx/OBSPublicDSAKey.pem --sparkle-framework ../../sparkle/Sparkle.framework --stable=$STABLE
../CI/install/osx/packageApp
../CI/install/osx/packageApp
.sh
# curl
cp
/usr/local/opt/curl/lib/libcurl.4.dylib ./OBS.app/Contents/Frameworks/
install_name_tool
-change
/usr/local/opt/curl/lib/libcurl.4.dylib @executable_path/../Frameworks/libcurl.4.dylib ./OBS.app/Contents/Plugins/rtmp-services.so
# luajit
install_name_tool
-change
/tmp/obsdeps/lib/libluajit-5.1.2.dylib @executable_path/../Frameworks/libluajit-5.1.2.dylib ./OBS.app/Contents/Plugins/frontend-tools.so
# jack
cp
/usr/local/opt/jack/lib/libjack.0.dylib ./OBS.app/Contents/Frameworks/
cp
/usr/local/opt/berkeley-db/lib/libdb-18.1.dylib ./OBS.app/Contents/Frameworks/
install_name_tool
-change
/usr/local/opt/jack/lib/libjack.0.dylib @executable_path/../Frameworks/libjack.0.dylib ./OBS.app/Contents/Plugins/linux-jack.so
install_name_tool
-change
/usr/local/opt/berkeley-db/lib/libdb-18.1.dylib @executable_path/../Frameworks/libdb-18.1.dylib ./OBS.app/Contents/Frameworks/libjack.0.dylib
# speexdsp
cp
/usr/local/opt/speexdsp/lib/libspeexdsp.1.dylib ./OBS.app/Contents/Frameworks/
install_name_tool
-change
/usr/local/opt/speexdsp/lib/libspeexdsp.1.dylib @executable_path/../Frameworks/libspeexdsp.1.dylib ./OBS.app/Contents/Plugins/obs-filters.so
# libmbedtls
# fix obs outputs
cp
/usr/local/opt/mbedtls/lib/libmbedtls.12.dylib ./OBS.app/Contents/Frameworks/
cp
/usr/local/opt/mbedtls/lib/libmbedcrypto.3.dylib ./OBS.app/Contents/Frameworks/
cp
/usr/local/opt/mbedtls/lib/libmbedx509.0.dylib ./OBS.app/Contents/Frameworks/
install_name_tool
-change
/usr/local/opt/mbedtls/lib/libmbedtls.12.dylib @executable_path/../Frameworks/libmbedtls.12.dylib ./OBS.app/Contents/Plugins/obs-outputs.so
install_name_tool
-change
/usr/local/opt/mbedtls/lib/libmbedcrypto.3.dylib @executable_path/../Frameworks/libmbedcrypto.3.dylib ./OBS.app/Contents/Plugins/obs-outputs.so
install_name_tool
-change
/usr/local/opt/mbedtls/lib/libmbedx509.0.dylib @executable_path/../Frameworks/libmbedx509.0.dylib ./OBS.app/Contents/Plugins/obs-outputs.so
install_name_tool
-change
/usr/local/opt/curl/lib/libcurl.4.dylib @executable_path/../Frameworks/libcurl.4.dylib ./OBS.app/Contents/Plugins/obs-outputs.so
install_name_tool
-change
@rpath/libobs.0.dylib @executable_path/../Frameworks/libobs.0.dylib ./OBS.app/Contents/Plugins/obs-outputs.so
# copy sparkle into the app
hr
"Copying Sparkle.framework"
...
...
@@ -76,9 +61,11 @@ install_name_tool -change /usr/local/opt/qt/lib/QtGui.framework/Versions/5/QtGui
install_name_tool
-change
/usr/local/opt/qt/lib/QtCore.framework/Versions/5/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore ./OBS.app/Contents/Plugins/obs-browser.so
install_name_tool
-change
/usr/local/opt/qt/lib/QtWidgets.framework/Versions/5/QtWidgets @executable_path/../Frameworks/QtWidgets.framework/Versions/5/QtWidgets ./OBS.app/Contents/Plugins/obs-browser.so
cp
../CI/install/osx/OBSPublicDSAKey.pem OBS.app/Contents/Resources
# edit plist
plutil
-insert
CFBundleVersion
-string
$GIT_TAG
-
$GIT_HASH
./OBS.app/Contents/Info.plist
plutil
-insert
CFBundleShortVersionString
-string
$GIT_TAG
-
$GIT_HASH
./OBS.app/Contents/Info.plist
plutil
-insert
CFBundleVersion
-string
$GIT_TAG
./OBS.app/Contents/Info.plist
plutil
-insert
CFBundleShortVersionString
-string
$GIT_TAG
./OBS.app/Contents/Info.plist
plutil
-insert
OBSFeedsURL
-string
https://obsproject.com/osx_update/feeds.xml ./OBS.app/Contents/Info.plist
plutil
-insert
SUFeedURL
-string
https://obsproject.com/osx_update/stable/updates.xml ./OBS.app/Contents/Info.plist
plutil
-insert
SUPublicDSAKeyFile
-string
OBSPublicDSAKey.pem ./OBS.app/Contents/Info.plist
...
...
CI/install-dependencies-osx.sh
浏览文件 @
32690926
...
...
@@ -30,7 +30,7 @@ sudo installer -pkg ./Packages.pkg -target /
brew update
#Base OBS Deps and ccache
brew
install
jack speexdsp ccache mbedtls clang-format
brew
install
jack speexdsp ccache mbedtls clang-format
freetype fdk-aac
brew
install
https://gist.githubusercontent.com/DDRBoxman/b3956fab6073335a4bf151db0dcbd4ad/raw/ed1342a8a86793ea8c10d8b4d712a654da121ace/qt.rb
brew
install
https://gist.githubusercontent.com/DDRBoxman/4cada55c51803a2f963fa40ce55c9d3e/raw/572c67e908bfbc1bcb8c476ea77ea3935133f5b5/swig.rb
...
...
CI/install/osx/dylibBundler
0 → 100755
浏览文件 @
32690926
文件已添加
CI/install/osx/packageApp
→
CI/install/osx/packageApp
.sh
浏览文件 @
32690926
rm
-rf
./OBS.app
mkdir
OBS.app
mkdir
OBS.app/Contents
mkdir
OBS.app/Contents/MacOS
...
...
@@ -10,16 +12,55 @@ cp ../CI/install/osx/obs.icns ./OBS.app/Contents/Resources
cp
-r
rundir/RelWithDebInfo/obs-plugins/ ./OBS.app/Contents/Plugins
cp
../CI/install/osx/Info.plist ./OBS.app/Contents
../CI/install/osx/dylibBundler
-b
-cd
-d
./OBS.app/Contents/Frameworks
-p
@executable_path/../Frameworks/
\
-s
./OBS.app/Contents/MacOS
\
-s
/usr/local/opt/mbedtls/lib/
\
-x
./OBS.app/Contents/Plugins/coreaudio-encoder.so
\
-x
./OBS.app/Contents/Plugins/decklink-ouput-ui.so
\
-x
./OBS.app/Contents/Plugins/frontend-tools.so
\
-x
./OBS.app/Contents/Plugins/image-source.so
\
-x
./OBS.app/Contents/Plugins/linux-jack.so
\
-x
./OBS.app/Contents/Plugins/mac-avcapture.so
\
-x
./OBS.app/Contents/Plugins/mac-capture.so
\
-x
./OBS.app/Contents/Plugins/mac-decklink.so
\
-x
./OBS.app/Contents/Plugins/mac-syphon.so
\
-x
./OBS.app/Contents/Plugins/mac-vth264.so
\
-x
./OBS.app/Contents/Plugins/obs-browser.so
\
-x
./OBS.app/Contents/Plugins/obs-browser-page
\
-x
./OBS.app/Contents/Plugins/obs-ffmpeg.so
\
-x
./OBS.app/Contents/Plugins/obs-filters.so
\
-x
./OBS.app/Contents/Plugins/obs-transitions.so
\
-x
./OBS.app/Contents/Plugins/obs-vst.so
\
-x
./OBS.app/Contents/Plugins/rtmp-services.so
\
-x
./OBS.app/Contents/MacOS/obs
\
-x
./OBS.app/Contents/MacOS/obs-ffmpeg-mux
\
-x
./OBS.app/Contents/MacOS/obslua.so
\
-x
./OBS.app/Contents/Plugins/obs-x264.so
\
-x
./OBS.app/Contents/Plugins/text-freetype2.so
\
-x
./OBS.app/Contents/Plugins/obs-libfdk.so
# -x ./OBS.app/Contents/Plugins/obs-outputs.so \
/usr/local/Cellar/qt/5.10.1/bin/macdeployqt ./OBS.app
install_name_tool -change /usr/local/opt/qt/lib/QtGui.framework/Versions/5/QtGui @executable_path/../Frameworks/QtGui.framework/Versions/5/QtGui ./OBS.app/Contents/Plugins/decklink-ouput-ui.so
mv
./OBS.app/Contents/MacOS/libobs-opengl.so ./OBS.app/Contents/Frameworks
install_name_tool -change /usr/local/opt/qt/lib/QtCore.framework/Versions/5/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore ./OBS.app/Contents/Plugins/decklink-ouput-ui.so
# put qt network in here becasuse streamdeck uses it
cp
-r
/usr/local/opt/qt/lib/QtNetwork.framework ./OBS.app/Contents/Frameworks
chmod
+w ./OBS.app/Contents/Frameworks/QtNetwork.framework/Versions/5/QtNetwork
install_name_tool
-change
/usr/local/Cellar/qt/5.10.1/lib/QtCore.framework/Versions/5/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore ./OBS.app/Contents/Frameworks/QtNetwork.framework/Versions/5/QtNetwork
# decklink ui qt
install_name_tool
-change
/usr/local/opt/qt/lib/QtGui.framework/Versions/5/QtGui @executable_path/../Frameworks/QtGui.framework/Versions/5/QtGui ./OBS.app/Contents/Plugins/decklink-ouput-ui.so
install_name_tool
-change
/usr/local/opt/qt/lib/QtCore.framework/Versions/5/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore ./OBS.app/Contents/Plugins/decklink-ouput-ui.so
install_name_tool
-change
/usr/local/opt/qt/lib/QtWidgets.framework/Versions/5/QtWidgets @executable_path/../Frameworks/QtWidgets.framework/Versions/5/QtWidgets ./OBS.app/Contents/Plugins/decklink-ouput-ui.so
# frontend tools qt
install_name_tool
-change
/usr/local/opt/qt/lib/QtGui.framework/Versions/5/QtGui @executable_path/../Frameworks/QtGui.framework/Versions/5/QtGui ./OBS.app/Contents/Plugins/frontend-tools.so
install_name_tool
-change
/usr/local/opt/qt/lib/QtCore.framework/Versions/5/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore ./OBS.app/Contents/Plugins/frontend-tools.so
install_name_tool
-change
/usr/local/opt/qt/lib/QtWidgets.framework/Versions/5/QtWidgets @executable_path/../Frameworks/QtWidgets.framework/Versions/5/QtWidgets ./OBS.app/Contents/Plugins/frontend-tools.so
install_name_tool -change /usr/local/opt/qt/lib/QtWidgets.framework/Versions/5/QtWidgets @executable_path/../Frameworks/QtWidgets.framework/Versions/5/QtWidgets ./OBS.app/Contents/Plugins/frontend-tools.so
\ No newline at end of file
# vst qt
install_name_tool
-change
/usr/local/opt/qt/lib/QtGui.framework/Versions/5/QtGui @executable_path/../Frameworks/QtGui.framework/Versions/5/QtGui ./OBS.app/Contents/Plugins/obs-vst.so
install_name_tool
-change
/usr/local/opt/qt/lib/QtCore.framework/Versions/5/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/5/QtCore ./OBS.app/Contents/Plugins/obs-vst.so
install_name_tool
-change
/usr/local/opt/qt/lib/QtWidgets.framework/Versions/5/QtWidgets @executable_path/../Frameworks/QtWidgets.framework/Versions/5/QtWidgets ./OBS.app/Contents/Plugins/obs-vst.so
install_name_tool
-change
/usr/local/opt/qt/lib/QtMacExtras.framework/Versions/5/QtMacExtras @executable_path/../Frameworks/QtMacExtras.framework/Versions/5/QtMacExtras ./OBS.app/Contents/Plugins/obs-vst.so
UI/platform-osx.mm
浏览文件 @
32690926
...
...
@@ -37,12 +37,14 @@ bool isInBundle()
bool
GetDataFilePath
(
const
char
*
data
,
string
&
output
)
{
if
(
isInBundle
())
{
NSBundle
*
myBundle
=
[
NSBundle
mainBundle
];
NSRunningApplication
*
app
=
[
NSRunningApplication
currentApplication
];
NSURL
*
bundleURL
=
[
app
bundleURL
];
NSString
*
path
=
[
NSString
stringWithFormat:
@"data/obs-studio/%@"
,
stringWithFormat:
@"
Contents/Resources/
data/obs-studio/%@"
,
[
NSString
stringWithUTF8String
:
data
]];
NS
String
*
absPath
=
[
myBundle
pathForResource
:
path
ofType
:
nil
];
output
=
[
absPath
UTF8String
];
NS
URL
*
dataURL
=
[
bundleURL
URLByAppendingPathComponent
:
path
];
output
=
[
[
dataURL
path
]
UTF8String
];
}
else
{
stringstream
str
;
str
<<
OBS_DATA_PATH
"/obs-studio/"
<<
data
;
...
...
deps/obs-scripting/CMakeLists.txt
浏览文件 @
32690926
...
...
@@ -12,6 +12,11 @@ if(MSVC)
w32-pthreads
)
endif
()
if
(
APPLE
)
set
(
obs-scripting_PLATFORM_DEPS
objc
)
endif
()
option
(
DISABLE_LUA
"Disable Lua scripting support"
OFF
)
option
(
DISABLE_PYTHON
"Disable Python scripting support"
OFF
)
...
...
deps/obs-scripting/obs-scripting-lua.c
浏览文件 @
32690926
...
...
@@ -43,7 +43,7 @@ static const char *startup_script_template = "\
for val in pairs(package.preload) do
\n
\
package.preload[val] = nil
\n
\
end
\n
\
package.cpath = package.cpath ..
\"
;
\"
..
\"
%s
\"
..
\"
/?."
SO_EXT
"
\"\n
\
package.cpath = package.cpath ..
\"
;
\"
..
\"
%s
/Contents/MacOS/?.so
\"
..
\"
;
\"
..
\"
%s
\"
..
\"
/?."
SO_EXT
"
\"\n
\
require
\"
obslua
\"\n
"
;
static
const
char
*
get_script_path_func
=
"\
...
...
@@ -1310,7 +1310,31 @@ void obs_lua_load(void)
/* ---------------------------------------------- */
/* Initialize Lua startup script */
dstr_printf
(
&
tmp
,
startup_script_template
,
SCRIPT_DIR
);
char
*
bundlePath
=
"./"
;
#ifdef __APPLE__
Class
nsRunningApplication
=
objc_lookUpClass
(
"NSRunningApplication"
);
SEL
currentAppSel
=
sel_getUid
(
"currentApplication"
);
typedef
id
(
*
running_app_func
)(
Class
,
SEL
);
running_app_func
operatingSystemName
=
(
running_app_func
)
objc_msgSend
;
id
app
=
operatingSystemName
(
nsRunningApplication
,
currentAppSel
);
typedef
id
(
*
bundle_url_func
)(
id
,
SEL
);
bundle_url_func
bundleURL
=
(
bundle_url_func
)
objc_msgSend
;
id
url
=
bundleURL
(
app
,
sel_getUid
(
"bundleURL"
));
typedef
id
(
*
url_path_func
)(
id
,
SEL
);
url_path_func
urlPath
=
(
url_path_func
)
objc_msgSend
;
id
path
=
urlPath
(
url
,
sel_getUid
(
"path"
));
typedef
id
(
*
string_func
)(
id
,
SEL
);
string_func
utf8String
=
(
string_func
)
objc_msgSend
;
bundlePath
=
(
char
*
)
utf8String
(
path
,
sel_registerName
(
"UTF8String"
));
#endif
dstr_printf
(
&
tmp
,
startup_script_template
,
bundlePath
,
SCRIPT_DIR
);
startup_script
=
tmp
.
array
;
dstr_free
(
&
dep_paths
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录