From patchwork Sat Oct 1 23:01:47 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Josh Dekker X-Patchwork-Id: 819 Delivered-To: ffmpegpatchwork@gmail.com Received: by 10.103.140.66 with SMTP id o63csp912913vsd; Sat, 1 Oct 2016 16:02:08 -0700 (PDT) X-Received: by 10.28.73.138 with SMTP id w132mr3398349wma.92.1475362928229; Sat, 01 Oct 2016 16:02:08 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id y6si27881321wjs.131.2016.10.01.16.02.07; Sat, 01 Oct 2016 16:02:08 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@itanimul.li; dkim=neutral (body hash did not verify) header.i=@messagingengine.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id F3F7468A0BF; Sun, 2 Oct 2016 02:01:51 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 2B7FF68A092 for ; Sun, 2 Oct 2016 02:01:45 +0300 (EEST) Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id CC9AB2050A for ; Sat, 1 Oct 2016 19:01:57 -0400 (EDT) Received: from frontend1 ([10.202.2.160]) by compute7.internal (MEProxy); Sat, 01 Oct 2016 19:01:57 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=itanimul.li; h= date:from:in-reply-to:message-id:references:subject:to :x-sasl-enc:x-sasl-enc; s=mesmtp; bh=zF7KbudnQOEutSuJwbrykdsZ+5I =; b=fRrn5qtMD1Tct4uxCXgn9Gebt+5PkTdPu06UhPrXrvflUWUjq5S2cEw8z/O LmtjgK+7oC/q5ndGrItCnwappTfqnaWFDYq9fMqEP7m6f+1aP7xEBFK3fuUANt9g ChRGiHzuFwpz1gvn52/kkaCTD2ZvGp5BFVnA8tMHz+IiVn5s= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=date:from:in-reply-to:message-id :references:subject:to:x-sasl-enc:x-sasl-enc; s=smtpout; bh=zF7K budnQOEutSuJwbrykdsZ+5I=; b=Ye3wlqsKSsexbmW5NNnghltKZvIJtpdJobyb JQDzbcq+/ZMfndRFgWyjrxRBQLyEKld2bAISSOZpWrU/e8hPwi0CEZv4fuwaqZxV whZlPaa+CWNFIdG62YKCsRWNvEL3/c7vycnNDujHQ6UKNUaGa2pjwupCAqY7v5Nm gKIeO/g= X-Sasl-enc: yr8Vpwy80UfdsllVCtxziHVYm0SqEh4WfU/BLFHc+D5s 1475362917 Received: from localhost (cpc75394-sotn16-2-0-cust168.15-1.cable.virginm.net [82.22.8.169]) by mail.messagingengine.com (Postfix) with ESMTPA id 4C87DF2985 for ; Sat, 1 Oct 2016 19:01:57 -0400 (EDT) From: Josh de Kock To: ffmpeg-devel@ffmpeg.org Date: Sun, 2 Oct 2016 00:01:47 +0100 Message-Id: <20161001230147.19593-2-josh@itanimul.li> X-Mailer: git-send-email 2.8.4 (Apple Git-73) In-Reply-To: <20161001230147.19593-1-josh@itanimul.li> References: <20161001230147.19593-1-josh@itanimul.li> Subject: [FFmpeg-devel] [PATCH 2/2] doc/developer: add sections for policies X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" And sort policies into these sections. Signed-off-by: Josh de Kock --- doc/developer.texi | 95 +++++++++++++++++++++++++++--------------------------- 1 file changed, 48 insertions(+), 47 deletions(-) diff --git a/doc/developer.texi b/doc/developer.texi index d4344ff..b85bf0f 100644 --- a/doc/developer.texi +++ b/doc/developer.texi @@ -246,8 +246,8 @@ For Emacs, add these roughly equivalent lines to your @file{.emacs.d/init.el}: @section Development Policy -@enumerate -@item Licenses for patches must be compatible with FFmpeg. +@subsection Patches/Committing +@subheading Licenses for patches must be compatible with FFmpeg. Contributions should be licensed under the @uref{http://www.gnu.org/licenses/lgpl-2.1.html, LGPL 2.1}, including an "or any later version" clause, or, if you prefer @@ -260,13 +260,13 @@ preferred. If you add a new file, give it a proper license header. Do not copy and paste it from a random place, use an existing file as template. -@item You must not commit code which breaks FFmpeg! +@subheading You must not commit code which breaks FFmpeg! This means unfinished code which is enabled and breaks compilation, compiles but does not work or breaks the regression tests). Always check the mailing list for any reviewers with issues and test FATE before you push. -@item Keep the main commit message short with an extended description below. +@subheading Keep the main commit message short with an extended description below. The commit message should have a short first line in the form of a @samp{topic: short description} as a header, separated by a newline from the body consisting of an explanation of why the change is necessary. @@ -274,14 +274,14 @@ If the commit fixes a known bug on the bug tracker, the commit message should include its bug ID. Referring to the issue on the bug tracker does not exempt you from writing an excerpt of the bug in the commit message. -@item Testing must be adequate but not is not required to be excessive. +@subheading Testing must be adequate but not is not required to be excessive. If it works for you, others, and passes FATE then it should be OK to commit it, provided it fits the other committing criteria. You should not worry about over-testing things. If your code has problems (portability, triggers compiler bugs, unusual environment etc) they will be reported and eventually fixed. -@item Do not commit unrelated changes together. +@subheading Do not commit unrelated changes together. They should be split them into self-contained pieces. Also do not forget that if part B depends on part A, but A does not depend on B, then A can and should be committed first and separate from B. Keeping changes well @@ -291,21 +291,7 @@ later on. Also if you have doubts about splitting or not splitting, do not hesitate to ask/discuss it on the developer mailing list. -@item API/ABI breakages and changes should be discussed before they are made. -Do not change behavior of the programs (renaming options etc) or public -API or ABI without first discussing it on the ffmpeg-devel mailing list. -Do not remove widely used functionality or features (redundant code can be removed). - -@item Ask before you change the build system (configure, etc). -Do not commit changes to the build system (Makefiles, configure script) -which change behavior, defaults etc, without asking first. The same -applies to compiler warning fixes, trivial looking fixes and to code -maintained by other developers. We usually have a reason for doing things -the way we do. Send your changes as patches to the ffmpeg-devel mailing -list, and if the code maintainers say OK, you may commit. This does not -apply to files you wrote and/or maintain. - -@item Cosmetic changes should be kept in separate patches. +@subheading Cosmetic changes should be kept in separate patches. We refuse source indentation and other cosmetic changes if they are mixed with functional changes, such commits will be rejected and removed. Every developer has his own indentation style, you should not change it. Of course @@ -319,7 +305,7 @@ NOTE: If you had to put if()@{ .. @} over a large (> 5 lines) chunk of code, then either do NOT change the indentation of the inner part within (do not move it to the right)! or do so in a separate commit -@item Commit messages should always be filled out properly. +@subheading Commit messages should always be filled out properly. Always fill out the commit log message. Describe in a few lines what you changed and why. You can refer to mailing list postings if you fix a particular bug. Comments such as "fixed!" or "Changed it." are unacceptable. @@ -331,44 +317,39 @@ area changed: Short 1 line description details describing what and why and giving references. @end example -@item Credit the author of the patch. +@subheading Credit the author of the patch. Make sure the author of the commit is set correctly. (see git commit --author) If you apply a patch, send an answer to ffmpeg-devel (or wherever you got the patch from) saying that you applied the patch. -@item Complex patches should refer to discussion surrounding them. +@subheading Complex patches should refer to discussion surrounding them. When applying patches that have been discussed (at length) on the mailing list, reference the thread in the log message. -@item Always wait long enough before pushing changes +@subheading Always wait long enough before pushing changes Do NOT commit to code actively maintained by others without permission. Send a patch to ffmpeg-devel. If no one answers within a reasonable time-frame (12h for build failures and security fixes, 3 days small changes, 1 week for big patches) then commit your patch if you think it is OK. Also note, the maintainer can simply ask for more time to review! -@item Subscribe to the ffmpeg-cvslog mailing list. -It is important to do this as the diffs of all commits are sent there and -reviewed by all the other developers. Bugs and possible improvements or -general questions regarding commits are discussed there. We expect you to -react if problems with your code are uncovered. - -@item Keep the documentation up to date. -Update the documentation if you change behavior or add features. If you are -unsure how best to do this, send a patch to ffmpeg-devel, the documentation -maintainer(s) will review and commit your stuff. - -@item Important discussions should be accessible to all. -Try to keep important discussions and requests (also) on the public -developer mailing list, so that all developers can benefit from them. +@subsection Code +@subheading API/ABI breakages and changes should be discussed before they are made. +Do not change behavior of the programs (renaming options etc) or public +API or ABI without first discussing it on the ffmpeg-devel mailing list. +Do not remove widely used functionality or features (redundant code can be removed). -@item -Never write to unallocated memory, never write over the end of arrays, -always check values read from some untrusted source before using them -as array index or other risky things. +@subheading Ask before you change the build system (configure, etc). +Do not commit changes to the build system (Makefiles, configure script) +which change behavior, defaults etc, without asking first. The same +applies to compiler warning fixes, trivial looking fixes and to code +maintained by other developers. We usually have a reason for doing things +the way we do. Send your changes as patches to the ffmpeg-devel mailing +list, and if the code maintainers say OK, you may commit. This does not +apply to files you wrote and/or maintain. -@item Remember to check if you need to bump versions for libav*. +@subheading Remember to check if you need to bump versions for libav*. Depending on the change, you may need to change the version integer. Incrementing the first component means no backward compatibility to previous versions (e.g. removal of a function from the public API). @@ -379,7 +360,7 @@ Incrementing the third component means a noteworthy binary compatible change (e.g. encoder bug fix that matters for the decoder). The third component always starts at 100 to distinguish FFmpeg from Libav. -@item Warnings for correct code may be disabled if there is no other option. +@subheading Warnings for correct code may be disabled if there is no other option. Compiler warnings indicate potential bugs or code with bad style. If a type of warning always points to correct and clean code, that warning should be disabled, not the code changed. @@ -388,13 +369,33 @@ If it is a bug, the bug has to be fixed. If it is not, the code should be changed to not generate a warning unless that causes a slowdown or obfuscates the code. -@item Check your entries in MAINTAINERS. +@subheading Check untrusted input properly. +Never write to unallocated memory, never write over the end of arrays, +always check values read from some untrusted source before using them +as array index or other risky things. + +@subsection Documentation/Other +@subheading Subscribe to the ffmpeg-cvslog mailing list. +It is important to do this as the diffs of all commits are sent there and +reviewed by all the other developers. Bugs and possible improvements or +general questions regarding commits are discussed there. We expect you to +react if problems with your code are uncovered. + +@subheading Keep the documentation up to date. +Update the documentation if you change behavior or add features. If you are +unsure how best to do this, send a patch to ffmpeg-devel, the documentation +maintainer(s) will review and commit your stuff. + +@subheading Important discussions should be accessible to all. +Try to keep important discussions and requests (also) on the public +developer mailing list, so that all developers can benefit from them. + +@subheading Check your entries in MAINTAINERS. Make sure that no parts of the codebase that you maintain are missing from the @file{MAINTAINERS} file. If something that you want to maintain is missing add it with your name after it. If at some point you no longer want to maintain some code, then please help in finding a new maintainer and also don't forget to update the @file{MAINTAINERS} file. -@end enumerate We think our rules are not too hard. If you have comments, contact us.