From: Clément Bœsch
Very incomplete, maybe splittable (split out the 3 first sections somewhere
an announce on the website)
Comments from other people who have done merges in the past very welcome,
notably on the last 2 sections.
doc/libav-merge.txt | 109
1 file changed, 109 insertions(+)
create mode 100644 doc/libav-merge.txt
diff --git a/doc/libav-merge.txt b/doc/libav-merge.txt
new file mode 100644
@@ -0,0 +1,109 @@
+The FFmpeg project merges all the changes from the Libav project
+(https://libav.org) since the origin of the
fork (around 2011).
+With the exceptions of some commits due to technical/political
+issues, the changes are merged on a more or less regular schedule (daily
+years thanks to Michael, but more sparse nowadays).
+The majority of the active developers believe the project needs to keep
+policy for various reasons.
+The most important one is that we don't want our users to have to choose
+between two distributors of libraries of the exact same name in order to
+different set of features and bugfixes. By taking the responsibility of
+unifying the two codebases, we allow users to benefit from the changes
+Today, FFmpeg has a much larger user database (we are distributed by every
+major distribution), so we consider this mission a priority.
+A different approach to the merge could have been to pick the changes we
+interested in and drop most of the cosmetics and other less important
+Unfortunately, this makes the following picks much harder, especially
+Libav project is involved in various deep API changes. As a result, we
+to virtually take everything done there.
+Any Libav developer is of course welcome anytime to contribute directly to
+FFmpeg tree. Of course, we fully understand and are forced to accept that
+few Libav developers are interested in doing so, but we still want to
+their work. This leads us to create merge commits for every single one
+Libav. The original commit appears totally unchanged with full authorship
+our history (and the conflict are solved in the merge one). That way, not
+single thing from Libav will be lost in the future in case some
+happens, or that project disappears one way or another.
+Of course, there are many downsides to this approach.
+- It causes a non negligible merge commits pollution. We make sure there
+ not several level of merges entangled (we do a 1:1 merge/commit), but
+ still a non-linear history.
+- Many duplicated work. For instance, we added libavresample in our tree
+ keep compatibility with Libav when our libswresample was already
+ exact same purpose. The same thing happened for various elements such as
+ ProRes support (but differences in features, bugs, licenses, ...). There
+ many work to do to unify them, and any help is very much welcome.
+- So much manpower from both FFmpeg and Libav is lost because of this
+ know it, and we don't know how to fix it. It takes incredible time to do
+ these merges, so we have even less time to work on things we personally
+ about. The bad vibes also do not help with keeping our developers
+- There is a growing technical risk factor with the merges due to the
+ differing more and more.
+The following gives developer guidelines on how to proceed when merging
+Before starting, you can reduce the risk of errors on merge conflicts by
+a different merge conflict style:
+ $ git config --global merge.conflictstyle diff3
+Here is a script to help merging the next commit in the queue:
+ if [ "$1" != "merge" -a "$1" != "noop" ]; then
+ printf "Usage: $0 \n"
+ exit 0
+ [ "$1" = "noop" ] && merge_opts="-s ours"
+ nextrev=$(git rev-list libav/master --not master --no-merges | tail
+ if [ -z "$nextrev" ]; then
+ printf "Nothing to merge..\n"
+ exit 0
+ printf "Merging $(git log -n 1 --oneline $nextrev)\n"
+ git merge --no-commit $merge_opts --no-ff --log $nextrev
+ if [ "$1" = "noop" -a -n "$2" ]; then
+ printf "\nThis commit is a noop, see $2\n" >> .git/MERGE_MSG
+ printf "\nMerged-by: $(git config --get user.name) <$(git config --get
user.email)>\n" >> .git/MERGE_MSG
+The script assumes a remote named libav.
+It has two modes: merge, and noop. The noop mode creates a merge with no
+to the HEAD. You can pass a hash as extra argument to reference a
+(it is common that we already have the change done in FFmpeg).
+- HEVC DSP and x86 MC SIMD improvements from Libav (see http://comments.gmane.org/gmane.comp.video.ffmpeg.devel/204917)
ffmpeg-devel mailing list