From patchwork Sun Nov 11 13:14:57 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Martin X-Patchwork-Id: 198271 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from hemlock.osuosl.org (hemlock.osuosl.org [140.211.166.133]) by ozlabs.org (Postfix) with ESMTP id 996272C0040 for ; Mon, 12 Nov 2012 00:17:01 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id CB04EA01D9; Sun, 11 Nov 2012 13:16:59 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id TolqsA6j7VJ5; Sun, 11 Nov 2012 13:16:56 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id 1787DA0164; Sun, 11 Nov 2012 13:16:56 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (whitealder.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id AA0A28F753 for ; Sun, 11 Nov 2012 13:15:53 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 822A38C2A6 for ; Sun, 11 Nov 2012 13:15:49 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id mqi9m6cIqy1Z for ; Sun, 11 Nov 2012 13:15:48 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-we0-f171.google.com (mail-we0-f171.google.com [74.125.82.171]) by whitealder.osuosl.org (Postfix) with ESMTPS id 3725A8C308 for ; Sun, 11 Nov 2012 13:15:48 +0000 (UTC) Received: by mail-we0-f171.google.com with SMTP id s43so3028443wey.16 for ; Sun, 11 Nov 2012 05:15:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; bh=sUn0ZBbvrsWQQ/RbDMYAkzY9rzFUZ/M1aSvGgfjhuHA=; b=uRFGiiqsbYCM+jxeSIYdrKFHUZrBjHJ3QPUVLw7/gPuhz89Zph0Y1HRElLhaO6zy3N WpwYbesj62JSb68Lwlh4G/21zJCiS8cV/KC5049aPnkhe0JGfkjTR6vuz9CQMIxPQ/tT SCqPug1dLpL0PIbqlLKMNF8SgSo1Gs8/WvETQH+tUQTku8lM3BghC4mNz2iiJfzzVypC 3L9yJF/uk5HTNWjg7c0LLGiS9mqcyCc0Qg/RCkyLFahaKmktc+3atuYz26BYNory/4gV hl6ZTzCWQ6vEuRl/gXQLxaLMYPWuGYtoQIlt5YIigmBkELZdQ2dMQeGhkvsNFsjHIJzh 1GgQ== Received: by 10.180.107.136 with SMTP id hc8mr10788868wib.9.1352639747867; Sun, 11 Nov 2012 05:15:47 -0800 (PST) Received: from localhost.localdomain (ivr94-4-82-229-165-48.fbx.proxad.net. [82.229.165.48]) by mx.google.com with ESMTPS id hv4sm10262550wib.0.2012.11.11.05.15.46 (version=SSLv3 cipher=OTHER); Sun, 11 Nov 2012 05:15:47 -0800 (PST) From: Samuel Martin To: buildroot@busybox.net Date: Sun, 11 Nov 2012 14:14:57 +0100 Message-Id: <1352639701-27829-20-git-send-email-s.martin49@gmail.com> X-Mailer: git-send-email 1.8.0 In-Reply-To: <1352639701-27829-1-git-send-email-s.martin49@gmail.com> References: <1352639701-27829-1-git-send-email-s.martin49@gmail.com> Subject: [Buildroot] [PATCH 19/23] manual: add adding-package-tips.txt X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: buildroot-bounces@busybox.net Signed-off-by: Samuel Martin create mode 100644 docs/manual/adding-packages-tips.txt diff --git a/docs/manual/adding-packages-tips.txt b/docs/manual/adding-packages-tips.txt new file mode 100644 index 0000000..acc73d3 --- /dev/null +++ b/docs/manual/adding-packages-tips.txt @@ -0,0 +1,54 @@ +// -*- mode:doc; -*- + +Tips and tricks +~~~~~~~~~~~~~~~ + +[[package-name-variable-relation]] +Package name, config entry name and makefile variable relationship +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +In Buildroot, there are some relation between: + +* the _package name_, which is the package directory name (and the + name of the +*.mk+ file); + +* the config entry name that is declared in the +Config.in+ file; + +* the makefile variable prefix. + +Thus, it is mandatory to keep consistency between all this stuff, +matching the following rules: + +* the _make_ target name will be the _package name_ itself (e.g.: + +foo-bar_boo+); + +* the config entry is the upper case _package name_ with `.` and `-` + characters substituted with `_`, prefixed with +BR2_PACKAGE_+ (e.g.: + +BR2_PACKAGE_FOO_BAR_BOO+); + +* the +*.mk+ file variable prefix is the upper case _package name_ + `.` and `-` characters substituted with `_` (e.g.: + +FOO_BAR_BOO_VERSION+). + + +[[github-download-url]] +How to add package from github +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +If the package has no release version, or its version cannot be +identified using tag, then the sha1 of the particular commit should be +used to identify the version (the first 7 characters of the sha1 are +enough): + +------------------------ +FOO_VERSION = 1234567 +FOO_SITE = http://github.com///tarball/ +------------------------ + +If the package version matches a tag, then this tag should be used to +identify the version: + +------------------------ +FOO_VERSION = v1.0 +FOO_SITE = http://github.com///tarball/$(FOO_VERSION) +------------------------ diff --git a/docs/manual/adding-packages.txt b/docs/manual/adding-packages.txt index 8221c85..b909d47 100644 --- a/docs/manual/adding-packages.txt +++ b/docs/manual/adding-packages.txt @@ -19,4 +19,6 @@ include::adding-packages-cmake.txt[] include::adding-packages-gettext.txt[] +include::adding-packages-tips.txt[] + include::adding-packages-conclusion.txt[]