* commit 'bf5f46b4cc47b7a4568119f224057d4ff91b6cdd': APIChanges: add entry for av_read_packet deprecation mxfdec: fix typo in mxf_read_seek() avserver: use freopen to redirect stdin/out/err to /dev/null avserver: remove daemon mode configure: Check for -Werror parameters on clang doxygen: remove obsolete options from Doxyfile configure: Add option to disable all command line programs Conflicts: Changelog configure doc/APIchanges doc/ffserver.conf doc/ffserver.texi ffserver.c
Unified · Split
| @@ -23,6 +23,7 @@ version <next>: · 22 unmodified lines | ||
| 23 | 23 | - field filter ported from libmpcodecs |
| 24 | 24 | - AVR demuxer |
| 25 | 25 | - geq filter ported from libmpcodecs |
| 26 | +- remove ffserver daemon mode | |
| 26 | 27 | |
| 27 | 28 | |
| 28 | 29 | version 1.0: |
| @@ -101,6 +101,13 @@ Configuration options: · 100 unmodified lines | ||
| 101 | 101 | --enable-gray enable full grayscale support (slower color) |
| 102 | 102 | --disable-swscale-alpha disable alpha channel support in swscale |
| 103 | 103 | |
| 104 | +Program options: | |
| 105 | + --disable-programs do not build command line programs | |
| 106 | + --disable-ffmpeg disable ffmpeg build | |
| 107 | + --disable-ffplay disable ffplay build | |
| 108 | + --disable-ffprobe disable ffprobe build | |
| 109 | + --disable-ffserver disable ffserver build | |
| 110 | + | |
| 104 | 111 | Documentation options: |
| 105 | 112 | --disable-doc do not build documentation |
| 106 | 113 | --disable-htmlpages do not build HTML documentation pages |
| @@ -109,10 +116,6 @@ Documentation options: · 2 unmodified lines | ||
| 109 | 116 | --disable-txtpages do not build text documentation pages |
| 110 | 117 | |
| 111 | 118 | Component options: |
| 112 | − --disable-ffmpeg disable ffmpeg build | |
| 113 | − --disable-ffplay disable ffplay build | |
| 114 | − --disable-ffprobe disable ffprobe build | |
| 115 | − --disable-ffserver disable ffserver build | |
| 116 | 119 | --disable-avdevice disable libavdevice build |
| 117 | 120 | --disable-avcodec disable libavcodec build |
| 118 | 121 | --disable-avformat disable libavformat build |
| @@ -2200,6 +2203,9 @@ for opt do · 2081 unmodified lines | ||
| 2200 | 2203 | ;; |
| 2201 | 2204 | --enable-debug=*) debuglevel="$optval" |
| 2202 | 2205 | ;; |
| 2206 | + --disable-programs) | |
| 2207 | + disable $PROGRAM_LIST | |
| 2208 | + ;; | |
| 2203 | 2209 | --disable-everything) |
| 2204 | 2210 | map 'eval unset \${$(toupper ${v%s})_LIST}' $COMPONENT_LIST |
| 2205 | 2211 | ;; |
| @@ -3954,6 +3960,8 @@ elif enabled llvm_gcc; then · 1748 unmodified lines | ||
| 3954 | 3960 | elif enabled clang; then |
| 3955 | 3961 | check_cflags -mllvm -stack-alignment=16 |
| 3956 | 3962 | check_cflags -Qunused-arguments |
| 3963 | + check_cflags -Werror=implicit-function-declaration | |
| 3964 | + check_cflags -Werror=missing-prototypes | |
| 3957 | 3965 | elif enabled armcc; then |
| 3958 | 3966 | # 2523: use of inline assembler is deprecated |
| 3959 | 3967 | add_cflags -W${armcc_opt},--diag_suppress=2523 |
| @@ -291,6 +291,10 @@ API changes, most recent first: · 290 unmodified lines | ||
| 291 | 291 | 2012-01-24 - 0c3577b - lavfi 2.60.100 |
| 292 | 292 | Add avfilter_graph_dump. |
| 293 | 293 | |
| 294 | +2012-03-20 - 3c90cc2 - lavfo 54.2.0 | |
| 295 | + Deprecate av_read_packet(), use av_read_frame() with | |
| 296 | + AVFMT_FLAG_NOPARSE | AVFMT_FLAG_NOFILLIN in AVFormatContext.flags | |
| 297 | + | |
| 294 | 298 | 2012-03-05 - lavc 54.8.0 |
| 295 | 299 | 6699d07 Add av_get_exact_bits_per_sample() |
| 296 | 300 | 9524cf7 Add av_get_audio_frame_duration() |
| @@ -489,12 +489,6 @@ MAX_INITIALIZER_LINES = 30 · 488 unmodified lines | ||
| 489 | 489 | |
| 490 | 490 | SHOW_USED_FILES = YES |
| 491 | 491 | |
| 492 | −# If the sources in your project are distributed over multiple directories | |
| 493 | −# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy | |
| 494 | −# in the documentation. The default is NO. | |
| 495 | − | |
| 496 | −SHOW_DIRECTORIES = NO | |
| 497 | − | |
| 498 | 492 | # Set the SHOW_FILES tag to NO to disable the generation of the Files page. |
| 499 | 493 | # This will remove the Files entry from the Quick Index and from the |
| 500 | 494 | # Folder Tree View (if specified). The default is YES. |
| @@ -847,12 +841,6 @@ HTML_COLORSTYLE_GAMMA = 80 · 346 unmodified lines | ||
| 847 | 841 | |
| 848 | 842 | HTML_TIMESTAMP = YES |
| 849 | 843 | |
| 850 | −# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, | |
| 851 | −# files or namespaces will be aligned in HTML using tables. If set to | |
| 852 | −# NO a bullet list will be used. | |
| 853 | − | |
| 854 | −HTML_ALIGN_MEMBERS = YES | |
| 855 | − | |
| 856 | 844 | # If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML |
| 857 | 845 | # documentation will contain sections that can be hidden and shown after the |
| 858 | 846 | # page has loaded. For this to work a browser that supports |
| @@ -1033,11 +1021,6 @@ ENUM_VALUES_PER_LINE = 4 · 174 unmodified lines | ||
| 1033 | 1021 | |
| 1034 | 1022 | GENERATE_TREEVIEW = NO |
| 1035 | 1023 | |
| 1036 | −# By enabling USE_INLINE_TREES, doxygen will generate the Groups, Directories, | |
| 1037 | −# and Class Hierarchy pages using a tree view instead of an ordered list. | |
| 1038 | − | |
| 1039 | −USE_INLINE_TREES = NO | |
| 1040 | − | |
| 1041 | 1024 | # If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be |
| 1042 | 1025 | # used to set the initial width (in pixels) of the frame in which the tree |
| 1043 | 1026 | # is shown. |
| @@ -25,10 +25,6 @@ MaxBandwidth 1000 · 24 unmodified lines | ||
| 25 | 25 | # '-' is the standard output. |
| 26 | 26 | CustomLog - |
| 27 | 27 | |
| 28 | −# Suppress that if you want to launch ffserver as a daemon. | |
| 29 | −NoDaemon | |
| 30 | − | |
| 31 | − | |
| 32 | 28 | ################################################################## |
| 33 | 29 | # Definition of the live feeds. Each live feed contains one video |
| 34 | 30 | # and/or audio sequence coming from an ffmpeg encoder or another |
| @@ -28,11 +28,6 @@ several live feeds, streaming from files and time shifting on live feeds · 27 unmodified lines | ||
| 28 | 28 | (you can seek to positions in the past on each live feed, provided you |
| 29 | 29 | specify a big enough feed storage in ffserver.conf). |
| 30 | 30 | |
| 31 | −ffserver runs in daemon mode by default; that is, it puts itself in | |
| 32 | −the background and detaches from its TTY, unless it is launched in | |
| 33 | −debug mode or a NoDaemon option is specified in the configuration | |
| 34 | −file. | |
| 35 | − | |
| 36 | 31 | This documentation covers only the streaming aspects of ffserver / |
| 37 | 32 | ffmpeg. All questions about parameters for ffmpeg, codec questions, |
| 38 | 33 | etc. are not covered here. Read @file{ffmpeg.html} for more |
| @@ -267,8 +262,7 @@ within the various <Stream> sections. Since ffserver will not launch · 228 unmodified lines | ||
| 267 | 262 | any ffmpeg instances, you will have to launch them manually. |
| 268 | 263 | @item -d |
| 269 | 264 | Enable debug mode. This option increases log verbosity, directs log |
| 270 | −messages to stdout and causes ffserver to run in the foreground | |
| 271 | −rather than as a daemon. | |
| 265 | +messages to stdout. | |
| 272 | 266 | @end table |
| 273 | 267 | @c man end |
| 274 | 268 | |
| @@ -29,6 +29,7 @@ · 28 unmodified lines | ||
| 29 | 29 | #endif |
| 30 | 30 | #include <string.h> |
| 31 | 31 | #include <stdlib.h> |
| 32 | +#include <stdio.h> | |
| 32 | 33 | #include "libavformat/avformat.h" |
| 33 | 34 | // FIXME those are internal headers, ffserver _really_ shouldn't use them |
| 34 | 35 | #include "libavformat/ffm.h" |
| @@ -306,12 +307,10 @@ static int rtp_new_av_stream(HTTPContext *c, · 271 unmodified lines | ||
| 306 | 307 | HTTPContext *rtsp_c); |
| 307 | 308 | |
| 308 | 309 | static const char *my_program_name; |
| 309 | −static const char *my_program_dir; | |
| 310 | 310 | |
| 311 | 311 | static const char *config_filename = "/etc/ffserver.conf"; |
| 312 | 312 | |
| 313 | 313 | static int ffserver_debug; |
| 314 | −static int ffserver_daemon; | |
| 315 | 314 | static int no_launch; |
| 316 | 315 | static int need_to_start_children; |
| 317 | 316 | |
| @@ -522,19 +521,12 @@ static void start_children(FFStream *feed) · 204 unmodified lines | ||
| 522 | 521 | close(i); |
| 523 | 522 | |
| 524 | 523 | if (!ffserver_debug) { |
| 525 | − i = open("/dev/null", O_RDWR); | |
| 526 | − if (i != -1) { | |
| 527 | − dup2(i, 0); | |
| 528 | − dup2(i, 1); | |
| 529 | − dup2(i, 2); | |
| 530 | − close(i); | |
| 531 | − } | |
| 532 | − } | |
| 533 | − | |
| 534 | − /* This is needed to make relative pathnames work */ | |
| 535 | − if (chdir(my_program_dir) < 0) { | |
| 536 | − http_log("chdir failed\n"); | |
| 537 | − exit(1); | |
| 524 | + if (!freopen("/dev/null", "r", stdin)) | |
| 525 | + http_log("failed to redirect STDIN to /dev/null\n;"); | |
| 526 | + if (!freopen("/dev/null", "w", stdout)) | |
| 527 | + http_log("failed to redirect STDOUT to /dev/null\n;"); | |
| 528 | + if (!freopen("/dev/null", "w", stderr)) | |
| 529 | + http_log("failed to redirect STDERR to /dev/null\n;"); | |
| 538 | 530 | } |
| 539 | 531 | |
| 540 | 532 | signal(SIGPIPE, SIG_DFL); |
| @@ -4122,8 +4114,6 @@ static int parse_ffconfig(const char *filename) · 3581 unmodified lines | ||
| 4122 | 4114 | if (resolve_host(&my_http_addr.sin_addr, arg) != 0) { |
| 4123 | 4115 | ERROR("%s:%d: Invalid host/IP address: %s\n", arg); |
| 4124 | 4116 | } |
| 4125 | − } else if (!av_strcasecmp(cmd, "NoDaemon")) { | |
| 4126 | − ffserver_daemon = 0; | |
| 4127 | 4117 | } else if (!av_strcasecmp(cmd, "RTSPPort")) { |
| 4128 | 4118 | get_arg(arg, sizeof(arg), &p); |
| 4129 | 4119 | val = atoi(arg); |
| @@ -4694,7 +4684,6 @@ static void handle_child_exit(int sig) · 564 unmodified lines | ||
| 4694 | 4684 | static void opt_debug(void) |
| 4695 | 4685 | { |
| 4696 | 4686 | ffserver_debug = 1; |
| 4697 | − ffserver_daemon = 0; | |
| 4698 | 4687 | logfilename[0] = '-'; |
| 4699 | 4688 | } |
| 4700 | 4689 | |
| @@ -4725,8 +4714,6 @@ int main(int argc, char **argv) · 24 unmodified lines | ||
| 4725 | 4714 | show_banner(argc, argv, options); |
| 4726 | 4715 | |
| 4727 | 4716 | my_program_name = argv[0]; |
| 4728 | − my_program_dir = getcwd(0, 0); | |
| 4729 | − ffserver_daemon = 1; | |
| 4730 | 4717 | |
| 4731 | 4718 | parse_options(NULL, argc, argv, options, NULL); |
| 4732 | 4719 | |
| @@ -4758,37 +4745,9 @@ int main(int argc, char **argv) · 25 unmodified lines | ||
| 4758 | 4745 | |
| 4759 | 4746 | compute_bandwidth(); |
| 4760 | 4747 | |
| 4761 | − /* put the process in background and detach it from its TTY */ | |
| 4762 | − if (ffserver_daemon) { | |
| 4763 | − int pid; | |
| 4764 | − | |
| 4765 | − pid = fork(); | |
| 4766 | − if (pid < 0) { | |
| 4767 | − perror("fork"); | |
| 4768 | − exit(1); | |
| 4769 | − } else if (pid > 0) { | |
| 4770 | − /* parent : exit */ | |
| 4771 | − exit(0); | |
| 4772 | − } else { | |
| 4773 | − /* child */ | |
| 4774 | − setsid(); | |
| 4775 | − close(0); | |
| 4776 | − open("/dev/null", O_RDWR); | |
| 4777 | − if (strcmp(logfilename, "-") != 0) { | |
| 4778 | − close(1); | |
| 4779 | − dup(0); | |
| 4780 | − } | |
| 4781 | − close(2); | |
| 4782 | − dup(0); | |
| 4783 | − } | |
| 4784 | − } | |
| 4785 | − | |
| 4786 | 4748 | /* signal init */ |
| 4787 | 4749 | signal(SIGPIPE, SIG_IGN); |
| 4788 | 4750 | |
| 4789 | − if (ffserver_daemon) | |
| 4790 | − chdir("/"); | |
| 4791 | − | |
| 4792 | 4751 | if (http_server() < 0) { |
| 4793 | 4752 | http_log("Could not start server\n"); |
| 4794 | 4753 | exit(1); |