Toggle navigation
Toggle navigation
此项目
正在载入...
Sign in
胡斌
/
srs
转到一个项目
Toggle navigation
项目
群组
代码片段
帮助
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
winlin
2014-04-04 11:36:22 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
1117f78587e67f557309443721101239ef5d1af2
1117f785
1 parent
f089eafd
support arm build for http api and server
隐藏空白字符变更
内嵌
并排对比
正在显示
2 个修改的文件
包含
44 行增加
和
19 行删除
trunk/auto/depends.sh
trunk/auto/options.sh
trunk/auto/depends.sh
查看文件 @
1117f78
...
...
@@ -242,20 +242,42 @@ if [ ! -f ${SRS_OBJS}/st/libst.so ]; then echo "build st-1.9 failed."; exit -1;
#####################################################################################
# http-parser-2.1
#####################################################################################
# check the arm flag file, if flag changed, need to rebuild the st.
if
[
$SRS_HTTP_PARSER
=
YES
]
;
then
if
[[
-f
${
SRS_OBJS
}
/hp/http_parser.h
&&
-f
${
SRS_OBJS
}
/hp/libhttp_parser.a
]]
;
then
echo
"http-parser-2.1 is ok."
;
# ok, arm specified, if the flag filed does not exists, need to rebuild.
if
[
$SRS_ARM_UBUNTU12
=
YES
]
;
then
if
[[
-f
${
SRS_OBJS
}
/_flag.st.hp.tmp
&&
-f
${
SRS_OBJS
}
/hp/http_parser.h
&&
-f
${
SRS_OBJS
}
/hp/libhttp_parser.a
]]
;
then
echo
"http-parser-2.1 for arm is ok."
;
else
echo
"build http-parser-2.1 for arm"
;
(
rm -rf
${
SRS_OBJS
}
/http-parser-2.1
&&
cd
${
SRS_OBJS
}
&&
unzip -q ../3rdparty/http-parser-2.1.zip
&&
cd
http-parser-2.1
&&
sed -i
"s/CPPFLAGS_FAST +=.*
$/
CPPFLAGS_FAST =
\$\(
CPPFLAGS_DEBUG
\)
/g"
Makefile
&&
sed -i
"s/CFLAGS_FAST =.*
$/
CFLAGS_FAST =
\$\(
CFLAGS_DEBUG
\)
/g"
Makefile
&&
make
CC
=
${
SrsArmCC
}
AR
=
${
SrsArmAR
}
package
&&
cd
..
&&
rm -rf hp
&&
ln -sf http-parser-2.1 hp
&&
cd
..
&&
touch
${
SRS_OBJS
}
/_flag.st.hp.tmp
)
fi
else
echo
"build http-parser-2.1"
;
(
rm -rf
${
SRS_OBJS
}
/http-parser-2.1
&&
cd
${
SRS_OBJS
}
&&
unzip -q ../3rdparty/http-parser-2.1.zip
&&
cd
http-parser-2.1
&&
sed -i
"s/CPPFLAGS_FAST +=.*
$/
CPPFLAGS_FAST =
\$\(
CPPFLAGS_DEBUG
\)
/g"
Makefile
&&
sed -i
"s/CFLAGS_FAST =.*
$/
CFLAGS_FAST =
\$\(
CFLAGS_DEBUG
\)
/g"
Makefile
&&
make package
&&
cd
..
&&
rm -rf hp
&&
ln -sf http-parser-2.1 hp
)
# arm not specified, if exists flag, need to rebuild for no-arm platform.
if
[[
! -f
${
SRS_OBJS
}
/_flag.st.hp.tmp
&&
-f
${
SRS_OBJS
}
/hp/http_parser.h
&&
-f
${
SRS_OBJS
}
/hp/libhttp_parser.a
]]
;
then
echo
"http-parser-2.1 is ok."
;
else
echo
"build http-parser-2.1"
;
(
rm -rf
${
SRS_OBJS
}
/http-parser-2.1
&&
cd
${
SRS_OBJS
}
&&
unzip -q ../3rdparty/http-parser-2.1.zip
&&
cd
http-parser-2.1
&&
sed -i
"s/CPPFLAGS_FAST +=.*
$/
CPPFLAGS_FAST =
\$\(
CPPFLAGS_DEBUG
\)
/g"
Makefile
&&
sed -i
"s/CFLAGS_FAST =.*
$/
CFLAGS_FAST =
\$\(
CFLAGS_DEBUG
\)
/g"
Makefile
&&
make package
&&
cd
..
&&
rm -rf hp
&&
ln -sf http-parser-2.1 hp
&&
cd
..
&&
rm -f
${
SRS_OBJS
}
/_flag.st.hp.tmp
)
fi
fi
# check status
ret
=
$?
;
if
[[
$ret
-ne 0
]]
;
then
echo
"build http-parser-2.1 failed, ret=
$ret
"
;
exit
$ret
;
fi
if
[[
! -f
${
SRS_OBJS
}
/hp/http_parser.h
]]
;
then
echo
"build http-parser-2.1 failed"
;
exit
-1;
fi
...
...
@@ -581,7 +603,7 @@ echo "" >> $SRS_AUTO_HEADERS_H
#####################################################################################
# generated the contributors from AUTHORS.txt
#####################################################################################
SRS_CONSTRIBUTORS
=
`
cat ../AUTHORS.txt|grep
"*"
|awk -F
'* '
'{print $2}'
`
SRS_CONSTRIBUTORS
=
`
cat ../AUTHORS.txt|grep
"*"
|awk -F
'
\
* '
'{print $2}'
`
echo
"#define SRS_CONSTRIBUTORS
\"\\
"
>>
$SRS_AUTO_HEADERS_H
for
CONTRIBUTOR
in
$SRS_CONSTRIBUTORS
;
do
echo
"
${
CONTRIBUTOR
}
\\
"
>>
$SRS_AUTO_HEADERS_H
...
...
trunk/auto/options.sh
查看文件 @
1117f78
...
...
@@ -97,11 +97,13 @@ do
--without-gcp
)
SRS_GPERF_CP
=
NO
;;
--without-gprof
)
SRS_GPROF
=
NO
;;
--without-arm-ubuntu12
)
SRS_ARM_UBUNTU12
=
NO
;;
--jobs
)
SRS_JOBS
=
${
value
}
;;
--prefix
)
SRS_PREFIX
=
${
value
}
;;
--static
)
SRS_STATIC
=
YES
;;
--dev
)
SRS_DEV
=
YES
;;
--arm
)
SRS_ARM_UBUNTU12
=
YES
;;
--pi
)
SRS_PI
=
YES
;;
*
)
...
...
@@ -116,13 +118,13 @@ done
#####################################################################################
# if arm specified, set some default to disabled.
if
[
$SRS_ARM_UBUNTU12
=
YES
]
;
then
if
[
$SRS_HLS
=
RESERVED
]
;
then
SRS_HLS
=
NO
;
fi
if
[
$SRS_HLS
=
RESERVED
]
;
then
SRS_HLS
=
YES
;
fi
if
[
$SRS_NGINX
=
RESERVED
]
;
then
SRS_NGINX
=
NO;
fi
if
[
$SRS_SSL
=
RESERVED
]
;
then
SRS_SSL
=
NO
;
fi
if
[
$SRS_SSL
=
RESERVED
]
;
then
SRS_SSL
=
YES
;
fi
if
[
$SRS_FFMPEG
=
RESERVED
]
;
then
SRS_FFMPEG
=
NO;
fi
if
[
$SRS_HTTP_CALLBACK
=
RESERVED
]
;
then
SRS_HTTP_CALLBACK
=
NO;
fi
if
[
$SRS_HTTP_SERVER
=
RESERVED
]
;
then
SRS_HTTP_SERVER
=
NO;
fi
if
[
$SRS_HTTP_API
=
RESERVED
]
;
then
SRS_HTTP_API
=
NO;
fi
if
[
$SRS_HTTP_SERVER
=
RESERVED
]
;
then
SRS_HTTP_SERVER
=
YES;
fi
if
[
$SRS_HTTP_API
=
RESERVED
]
;
then
SRS_HTTP_API
=
YES;
fi
if
[
$SRS_LIBRTMP
=
RESERVED
]
;
then
SRS_LIBRTMP
=
NO;
fi
if
[
$SRS_BWTC
=
RESERVED
]
;
then
SRS_BWTC
=
NO;
fi
if
[
$SRS_RESEARCH
=
RESERVED
]
;
then
SRS_RESEARCH
=
NO;
fi
...
...
@@ -143,8 +145,8 @@ else
if
[
$SRS_SSL
=
RESERVED
]
;
then
SRS_SSL
=
YES;
fi
if
[
$SRS_FFMPEG
=
RESERVED
]
;
then
SRS_FFMPEG
=
NO;
fi
if
[
$SRS_HTTP_CALLBACK
=
RESERVED
]
;
then
SRS_HTTP_CALLBACK
=
NO;
fi
if
[
$SRS_HTTP_SERVER
=
RESERVED
]
;
then
SRS_HTTP_SERVER
=
NO;
fi
if
[
$SRS_HTTP_API
=
RESERVED
]
;
then
SRS_HTTP_API
=
NO;
fi
if
[
$SRS_HTTP_SERVER
=
RESERVED
]
;
then
SRS_HTTP_SERVER
=
YES;
fi
if
[
$SRS_HTTP_API
=
RESERVED
]
;
then
SRS_HTTP_API
=
YES;
fi
if
[
$SRS_LIBRTMP
=
RESERVED
]
;
then
SRS_LIBRTMP
=
NO;
fi
if
[
$SRS_BWTC
=
RESERVED
]
;
then
SRS_BWTC
=
NO;
fi
if
[
$SRS_RESEARCH
=
RESERVED
]
;
then
SRS_RESEARCH
=
NO;
fi
...
...
@@ -270,6 +272,7 @@ if [ $help = yes ]; then
--prefix=<path> the absolute install path for srs.
--dev for dev, open all features, no gperf/gprof/arm.
--pi for raspberry-pi(directly build), open features hls/ssl/static.
--arm alias for --with-arm-ubuntu12
END
exit
0
...
...
请
注册
或
登录
后发表评论