正在显示
4 个修改的文件
包含
51 行增加
和
36 行删除
@@ -469,43 +469,47 @@ fi | @@ -469,43 +469,47 @@ fi | ||
469 | # Affected users should upgrade to OpenSSL 1.0.1g. Users unable to immediately | 469 | # Affected users should upgrade to OpenSSL 1.0.1g. Users unable to immediately |
470 | # upgrade can alternatively recompile OpenSSL with -DOPENSSL_NO_HEARTBEATS. | 470 | # upgrade can alternatively recompile OpenSSL with -DOPENSSL_NO_HEARTBEATS. |
471 | if [ $SRS_SSL = YES ]; then | 471 | if [ $SRS_SSL = YES ]; then |
472 | - # check the arm flag file, if flag changed, need to rebuild the st. | ||
473 | - if [ $SRS_ARM_UBUNTU12 = YES ]; then | ||
474 | - # ok, arm specified, if the flag filed does not exists, need to rebuild. | ||
475 | - if [[ -f ${SRS_OBJS}/_flag.ssl.arm.tmp && -f ${SRS_OBJS}/openssl/lib/libssl.a ]]; then | ||
476 | - echo "openssl-1.0.1f for arm is ok."; | ||
477 | - else | ||
478 | - echo "build openssl-1.0.1f for arm"; | ||
479 | - ( | ||
480 | - rm -rf ${SRS_OBJS}/openssl-1.0.1f && cd ${SRS_OBJS} && | ||
481 | - unzip -q ../3rdparty/openssl-1.0.1f.zip && cd openssl-1.0.1f && | ||
482 | - ./Configure --prefix=`pwd`/_release -no-shared no-asm linux-armv4 -DOPENSSL_NO_HEARTBEATS && | ||
483 | - make CC=${SrsArmCC} GCC=${SrsArmGCC} AR="${SrsArmAR} r" \ | ||
484 | - LD=${SrsArmLD} LINK=${SrsArmGCC} RANDLIB=${SrsArmRANDLIB} && | ||
485 | - make install && | ||
486 | - cd .. && rm -rf openssl && ln -sf openssl-1.0.1f/_release openssl && | ||
487 | - cd .. && touch ${SRS_OBJS}/_flag.ssl.arm.tmp | ||
488 | - ) | ||
489 | - fi | 472 | + if [ $SRS_USE_SYS_SSL = YES ]; then |
473 | + echo "warning: donot compile ssl, use system ssl" | ||
490 | else | 474 | else |
491 | - # arm not specified, if exists flag, need to rebuild for no-arm platform. | ||
492 | - if [[ ! -f ${SRS_OBJS}/_flag.ssl.arm.tmp && -f ${SRS_OBJS}/openssl/lib/libssl.a ]]; then | ||
493 | - echo "openssl-1.0.1f is ok."; | 475 | + # check the arm flag file, if flag changed, need to rebuild the st. |
476 | + if [ $SRS_ARM_UBUNTU12 = YES ]; then | ||
477 | + # ok, arm specified, if the flag filed does not exists, need to rebuild. | ||
478 | + if [[ -f ${SRS_OBJS}/_flag.ssl.arm.tmp && -f ${SRS_OBJS}/openssl/lib/libssl.a ]]; then | ||
479 | + echo "openssl-1.0.1f for arm is ok."; | ||
480 | + else | ||
481 | + echo "build openssl-1.0.1f for arm"; | ||
482 | + ( | ||
483 | + rm -rf ${SRS_OBJS}/openssl-1.0.1f && cd ${SRS_OBJS} && | ||
484 | + unzip -q ../3rdparty/openssl-1.0.1f.zip && cd openssl-1.0.1f && | ||
485 | + ./Configure --prefix=`pwd`/_release -no-shared no-asm linux-armv4 -DOPENSSL_NO_HEARTBEATS && | ||
486 | + make CC=${SrsArmCC} GCC=${SrsArmGCC} AR="${SrsArmAR} r" \ | ||
487 | + LD=${SrsArmLD} LINK=${SrsArmGCC} RANDLIB=${SrsArmRANDLIB} && | ||
488 | + make install && | ||
489 | + cd .. && rm -rf openssl && ln -sf openssl-1.0.1f/_release openssl && | ||
490 | + cd .. && touch ${SRS_OBJS}/_flag.ssl.arm.tmp | ||
491 | + ) | ||
492 | + fi | ||
494 | else | 493 | else |
495 | - echo "build openssl-1.0.1f"; | ||
496 | - ( | ||
497 | - rm -rf ${SRS_OBJS}/openssl-1.0.1f && cd ${SRS_OBJS} && | ||
498 | - unzip -q ../3rdparty/openssl-1.0.1f.zip && cd openssl-1.0.1f && | ||
499 | - ./config --prefix=`pwd`/_release -no-shared -DOPENSSL_NO_HEARTBEATS && | ||
500 | - make && make install && | ||
501 | - cd .. && rm -rf openssl && ln -sf openssl-1.0.1f/_release openssl && | ||
502 | - cd .. && rm -f ${SRS_OBJS}/_flag.ssl.arm.tmp | ||
503 | - ) | 494 | + # arm not specified, if exists flag, need to rebuild for no-arm platform. |
495 | + if [[ ! -f ${SRS_OBJS}/_flag.ssl.arm.tmp && -f ${SRS_OBJS}/openssl/lib/libssl.a ]]; then | ||
496 | + echo "openssl-1.0.1f is ok."; | ||
497 | + else | ||
498 | + echo "build openssl-1.0.1f"; | ||
499 | + ( | ||
500 | + rm -rf ${SRS_OBJS}/openssl-1.0.1f && cd ${SRS_OBJS} && | ||
501 | + unzip -q ../3rdparty/openssl-1.0.1f.zip && cd openssl-1.0.1f && | ||
502 | + ./config --prefix=`pwd`/_release -no-shared -DOPENSSL_NO_HEARTBEATS && | ||
503 | + make && make install && | ||
504 | + cd .. && rm -rf openssl && ln -sf openssl-1.0.1f/_release openssl && | ||
505 | + cd .. && rm -f ${SRS_OBJS}/_flag.ssl.arm.tmp | ||
506 | + ) | ||
507 | + fi | ||
504 | fi | 508 | fi |
509 | + # check status | ||
510 | + ret=$?; if [[ $ret -ne 0 ]]; then echo "build openssl-1.0.1f failed, ret=$ret"; exit $ret; fi | ||
511 | + if [ ! -f ${SRS_OBJS}/openssl/lib/libssl.a ]; then echo "build openssl-1.0.1f failed."; exit -1; fi | ||
505 | fi | 512 | fi |
506 | - # check status | ||
507 | - ret=$?; if [[ $ret -ne 0 ]]; then echo "build openssl-1.0.1f failed, ret=$ret"; exit $ret; fi | ||
508 | - if [ ! -f ${SRS_OBJS}/openssl/lib/libssl.a ]; then echo "build openssl-1.0.1f failed."; exit -1; fi | ||
509 | fi | 513 | fi |
510 | 514 | ||
511 | if [ $SRS_SSL = YES ]; then | 515 | if [ $SRS_SSL = YES ]; then |
@@ -47,6 +47,10 @@ SRS_PREFIX=/usr/local/srs | @@ -47,6 +47,10 @@ SRS_PREFIX=/usr/local/srs | ||
47 | SRS_JOBS=1 | 47 | SRS_JOBS=1 |
48 | SRS_STATIC=RESERVED | 48 | SRS_STATIC=RESERVED |
49 | # | 49 | # |
50 | +# experts | ||
51 | +# donot compile ssl, use system ssl(-lssl) if required. | ||
52 | +SRS_USE_SYS_SSL=NO | ||
53 | +# | ||
50 | # presets | 54 | # presets |
51 | # for x86/x64 pc/servers | 55 | # for x86/x64 pc/servers |
52 | SRS_X86_X64=NO | 56 | SRS_X86_X64=NO |
@@ -143,6 +147,9 @@ Conflicts: | @@ -143,6 +147,9 @@ Conflicts: | ||
143 | 4. --arm vs --with-ffmpeg/bwtc/gperf/gmc/gmp/gprof: | 147 | 4. --arm vs --with-ffmpeg/bwtc/gperf/gmc/gmp/gprof: |
144 | the complex tools not available for arm. | 148 | the complex tools not available for arm. |
145 | 149 | ||
150 | +Experts: | ||
151 | + --use-sys-ssl donot compile ssl, use system ssl(-lssl) if required. | ||
152 | + | ||
146 | Workflow: | 153 | Workflow: |
147 | 1. apply "Presets". if not specified, use default preset. | 154 | 1. apply "Presets". if not specified, use default preset. |
148 | 2. apply "Options". user specified option will override the preset. | 155 | 2. apply "Options". user specified option will override the preset. |
@@ -210,6 +217,8 @@ function parse_user_option() { | @@ -210,6 +217,8 @@ function parse_user_option() { | ||
210 | --fast) SRS_FAST=YES ;; | 217 | --fast) SRS_FAST=YES ;; |
211 | --pure-rtmp) SRS_PURE_RTMP=YES ;; | 218 | --pure-rtmp) SRS_PURE_RTMP=YES ;; |
212 | --rtmp-hls) SRS_RTMP_HLS=YES ;; | 219 | --rtmp-hls) SRS_RTMP_HLS=YES ;; |
220 | + | ||
221 | + --use-sys-ssl) SRS_USE_SYS_SSL=YES ;; | ||
213 | 222 | ||
214 | *) | 223 | *) |
215 | echo "$0: error: invalid option \"$option\"" | 224 | echo "$0: error: invalid option \"$option\"" |
@@ -396,12 +396,14 @@ LibHttpParserRoot=""; LibHttpParserfile="" | @@ -396,12 +396,14 @@ LibHttpParserRoot=""; LibHttpParserfile="" | ||
396 | if [ $SRS_HTTP_PARSER = YES ]; then LibHttpParserRoot="${SRS_OBJS}/hp"; LibHttpParserfile="${LibHttpParserRoot}/libhttp_parser.a"; fi | 396 | if [ $SRS_HTTP_PARSER = YES ]; then LibHttpParserRoot="${SRS_OBJS}/hp"; LibHttpParserfile="${LibHttpParserRoot}/libhttp_parser.a"; fi |
397 | # openssl-1.0.1f, for the RTMP complex handshake. | 397 | # openssl-1.0.1f, for the RTMP complex handshake. |
398 | LibSSLRoot="";LibSSLfile="" | 398 | LibSSLRoot="";LibSSLfile="" |
399 | -if [ $SRS_SSL = YES ]; then LibSSLRoot="${SRS_OBJS}/openssl/include"; LibSSLfile="${SRS_OBJS}/openssl/lib/libssl.a ${SRS_OBJS}/openssl/lib/libcrypto.a"; fi | 399 | +if [ $SRS_SSL = YES ]; then if [ $SRS_USE_SYS_SSL = NO ]; then LibSSLRoot="${SRS_OBJS}/openssl/include"; LibSSLfile="${SRS_OBJS}/openssl/lib/libssl.a ${SRS_OBJS}/openssl/lib/libcrypto.a"; fi fi |
400 | # gperftools-2.1, for mem check and mem/cpu profile | 400 | # gperftools-2.1, for mem check and mem/cpu profile |
401 | LibGperfRoot=""; LibGperfFile="" | 401 | LibGperfRoot=""; LibGperfFile="" |
402 | if [ $SRS_GPERF = YES ]; then LibGperfRoot="${SRS_OBJS}/gperf/include"; LibGperfFile="${SRS_OBJS}/gperf/lib/libtcmalloc_and_profiler.a"; fi | 402 | if [ $SRS_GPERF = YES ]; then LibGperfRoot="${SRS_OBJS}/gperf/include"; LibGperfFile="${SRS_OBJS}/gperf/lib/libtcmalloc_and_profiler.a"; fi |
403 | # the link options, always use static link | 403 | # the link options, always use static link |
404 | -SrsLinkOptions=""; if [ $SRS_STATIC = YES ]; then SrsLinkOptions="-static"; else SrsLinkOptions="-ldl"; fi | 404 | +SrsLinkOptions=""; |
405 | +if [ $SRS_SSL = YES ]; then if [ $SRS_USE_SYS_SSL = YES ]; then SrsLinkOptions="-lssl"; fi fi | ||
406 | +if [ $SRS_STATIC = YES ]; then SrsLinkOptions="${SrsLinkOptions} -static"; else SrsLinkOptions="${SrsLinkOptions} -ldl"; fi | ||
405 | 407 | ||
406 | ##################################################################################### | 408 | ##################################################################################### |
407 | # Modules, compile each module, then link to binary | 409 | # Modules, compile each module, then link to binary |
@@ -31,7 +31,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | @@ -31,7 +31,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | ||
31 | // current release version | 31 | // current release version |
32 | #define VERSION_MAJOR "0" | 32 | #define VERSION_MAJOR "0" |
33 | #define VERSION_MINOR "9" | 33 | #define VERSION_MINOR "9" |
34 | -#define VERSION_REVISION "66" | 34 | +#define VERSION_REVISION "67" |
35 | #define RTMP_SIG_SRS_VERSION VERSION_MAJOR"."VERSION_MINOR"."VERSION_REVISION | 35 | #define RTMP_SIG_SRS_VERSION VERSION_MAJOR"."VERSION_MINOR"."VERSION_REVISION |
36 | // server info. | 36 | // server info. |
37 | #define RTMP_SIG_SRS_KEY "srs" | 37 | #define RTMP_SIG_SRS_KEY "srs" |
-
请 注册 或 登录 后发表评论