winlin

refine macro, use ffmpeg_stub and ffmpeg_tool, 0.9.224

@@ -658,12 +658,19 @@ if [ $SRS_FFMPEG_TOOL = YES ]; then @@ -658,12 +658,19 @@ if [ $SRS_FFMPEG_TOOL = YES ]; then
658 if [ ! -f ${SRS_OBJS}/ffmpeg/bin/ffmpeg ]; then echo "build ffmpeg-2.1 failed."; exit -1; fi 658 if [ ! -f ${SRS_OBJS}/ffmpeg/bin/ffmpeg ]; then echo "build ffmpeg-2.1 failed."; exit -1; fi
659 fi 659 fi
660 660
  661 +# whether compile ffmpeg tool
  662 +if [ $SRS_FFMPEG_TOOL = YES ]; then
  663 + echo "#define SRS_AUTO_FFMPEG_TOOL" >> $SRS_AUTO_HEADERS_H
  664 +else
  665 + echo "#undef SRS_AUTO_FFMPEG_TOOL" >> $SRS_AUTO_HEADERS_H
  666 +fi
  667 +
661 # whatever the FFMPEG tools, if transcode and ingest specified, 668 # whatever the FFMPEG tools, if transcode and ingest specified,
662 # srs always compile the FFMPEG tool stub which used to start the FFMPEG process. 669 # srs always compile the FFMPEG tool stub which used to start the FFMPEG process.
663 if [ $SRS_FFMPEG_STUB = YES ]; then 670 if [ $SRS_FFMPEG_STUB = YES ]; then
664 - echo "#define SRS_AUTO_FFMPEG" >> $SRS_AUTO_HEADERS_H 671 + echo "#define SRS_AUTO_FFMPEG_STUB" >> $SRS_AUTO_HEADERS_H
665 else 672 else
666 - echo "#undef SRS_AUTO_FFMPEG" >> $SRS_AUTO_HEADERS_H 673 + echo "#undef SRS_AUTO_FFMPEG_STUB" >> $SRS_AUTO_HEADERS_H
667 fi 674 fi
668 675
669 if [ $SRS_TRANSCODE = YES ]; then 676 if [ $SRS_TRANSCODE = YES ]; then
@@ -36,7 +36,7 @@ using namespace std; @@ -36,7 +36,7 @@ using namespace std;
36 #include <srs_kernel_log.hpp> 36 #include <srs_kernel_log.hpp>
37 #include <srs_app_config.hpp> 37 #include <srs_app_config.hpp>
38 38
39 -#ifdef SRS_AUTO_FFMPEG 39 +#ifdef SRS_AUTO_FFMPEG_STUB
40 40
41 #define SRS_RTMP_ENCODER_COPY "copy" 41 #define SRS_RTMP_ENCODER_COPY "copy"
42 #define SRS_RTMP_ENCODER_NO_VIDEO "vn" 42 #define SRS_RTMP_ENCODER_NO_VIDEO "vn"
@@ -29,7 +29,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. @@ -29,7 +29,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
29 */ 29 */
30 #include <srs_core.hpp> 30 #include <srs_core.hpp>
31 31
32 -#ifdef SRS_AUTO_FFMPEG 32 +#ifdef SRS_AUTO_FFMPEG_STUB
33 33
34 #include <string> 34 #include <string>
35 #include <vector> 35 #include <vector>
@@ -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 "223" 34 +#define VERSION_REVISION "224"
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"
@@ -125,7 +125,7 @@ void show_macro_features() @@ -125,7 +125,7 @@ void show_macro_features()
125 srs_warn("compile nginx: off"); 125 srs_warn("compile nginx: off");
126 #endif 126 #endif
127 127
128 -#ifdef SRS_AUTO_FFMPEG 128 +#ifdef SRS_AUTO_FFMPEG_TOOL
129 srs_trace("compile ffmpeg: on"); 129 srs_trace("compile ffmpeg: on");
130 #else 130 #else
131 srs_warn("compile ffmpeg: off"); 131 srs_warn("compile ffmpeg: off");