From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 03/17] ustr: new package
Date: Thu, 5 Sep 2013 09:57:49 +0200 [thread overview]
Message-ID: <20130905095749.25465b8e@skate> (raw)
In-Reply-To: <1378336196-27403-4-git-send-email-clshotwe@rockwellcollins.com>
Dear Clayton Shotwell,
On Wed, 4 Sep 2013 18:09:42 -0500, Clayton Shotwell wrote:
> diff --git a/package/ustr/ustr-1.0.4-crossCompileModifications.patch b/package/ustr/ustr-1.0.4-crossCompileModifications.patch
Patch names should not contain the version number, but instead a number
that allows patches to be applied in the right order. See
http://buildroot.org/downloads/manual/manual.html#patch-policy.
Also, while it is not written anywhere explicitly, the patch filename
should be all in lower case.
> new file mode 100644
> index 0000000..aad9b81
The patch should contain a description + Signed-off-by line. See
http://buildroot.org/downloads/manual/manual.html#_format_and_licensing_of_the_package_patches.
> diff --git a/package/ustr/ustr.mk b/package/ustr/ustr.mk
> new file mode 100644
> index 0000000..46b8bb4
> --- /dev/null
> +++ b/package/ustr/ustr.mk
> @@ -0,0 +1,68 @@
> +#############################################################
> +#
> +# ustr
> +#
> +#############################################################
80 dashes, one empty line between header and variables.
> +USTR_VERSION = 1.0.4
> +USTR_SOURCE = ustr-$(USTR_VERSION).tar.bz2
> +USTR_SITE = http://www.and.org/ustr/$(USTR_VERSION)/
> +USTR_LICENSE = BSD-2c MIT LGPLv2+
> +USTR_LICENSE_FILES = LICENCE LICENSE_BSD LICENSE_LGPL LICENSE_MIT
> +
> +##############################
> +# Target Section
> +##############################
Comment not needed.
> +USTR_INSTALL_STAGING = YES
> +USTR_INSTALL_TARGET = YES
Last line not needed.
> +
> +USTR_MAKE_CMDS = $(TARGET_CONFIGURE_OPTS)
Use $(TARGET_CONFIGURE_OPTS) directly.
> +
> +define USTR_BUILD_CMDS
> + $(MAKE) -C $(@D) all $(USTR_MAKE_CMDS) DESTDIR=$(STAGING_DIR)
> + $(MAKE) -C $(@D) all-shared $(USTR_MAKE_CMDS) DESTDIR=$(STAGING_DIR)
DESTDIR typically not needed when building. Also, you can probably
combine this in one line:
$(MAKE) -C $(@D) \
$(USTR_MAKE_CMDS) all all-shared
However, there's one thing we've forgotten: we try to support static
library builds in Buildroot, when BR2_PREFER_STATIC_LIB is enabled. So
when it's possible, it'd be great if the packages could behave nicely
when BR2_PREFER_STATIC_LIB=y (by disabling the build of shared
libraries). If it's not possible or too complicated, we can add a
depends on !BR2_PREFER_STATIC_LIB.
> +endef
> +
> +define USTR_INSTALL_STAGING_CMDS
> + $(MAKE) -C $(@D) install $(USTR_MAKE_CMDS) DESTDIR=$(STAGING_DIR)
> +endef
> +
> +define USTR_INSTALL_TARGET_CMDS
> + $(MAKE) -C $(@D) install $(USTR_MAKE_CMDS) DESTDIR=$(TARGET_DIR)
> +endef
> +
> +define USTR_CLEAN_CMDS
> + $(MAKE) -C $(@D) clean
> +endef
> +
> +define USTR_UNINSTALL_STAGING_CMDS
> + rm -rf $(addprefix $(TARGET_DIR),/usr/lib/libustr* /usr/lib/pkgconfig/ustr* \
> + /usr/bin/ustr* /usr/include/ustr* /usr/include/ \
> + /usr/share/doc/ustr-$(USTR_VERSION) /usr/share/ustr-$(USTR_VERSION) \
> + /usr/share/man/man1/ustr* /usr/share/man/man3/ustr*)
> +endef
> +
> +define USTR_UNINSTALL_TARGET_CMDS
> + rm -rf $(addprefix $(TARGET_DIR),/usr/lib/libustr* /usr/lib/pkgconfig/ustr* \
> + /usr/bin/ustr* /usr/include/ustr*)
> +endef
Drop the uninstall comands.
> +##############################
> +# Host Section
> +##############################
> +HOST_USTR_MAKE_CMDS = $(HOST_CONFIGURE_OPTS)
> +
> +define HOST_USTR_BUILD_CMDS
> + $(MAKE) -C $(@D) all $(HOST_USTR_MAKE_CMDS) DESTDIR=$(HOST_DIR)
> + $(MAKE) -C $(@D) all-shared $(HOST_USTR_MAKE_CMDS) DESTDIR=$(HOST_DIR)
> +endef
Same comments as above, for everything :)
Thanks!
Thomas
--
Thomas Petazzoni, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com
next prev parent reply other threads:[~2013-09-05 7:57 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-04 23:09 [Buildroot] [PATCH 00/17] SELinux Buildroot Additions Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 01/17] libsepol: new package Clayton Shotwell
2013-09-05 7:44 ` Thomas Petazzoni
2013-09-05 12:58 ` clshotwe at rockwellcollins.com
2013-09-05 13:19 ` Thomas Petazzoni
2013-09-05 16:46 ` Arnout Vandecappelle
2013-09-06 6:28 ` Thomas Petazzoni
2013-09-09 17:36 ` Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 02/17] libselinux: " Clayton Shotwell
2013-09-05 7:51 ` Thomas Petazzoni
2013-09-05 13:18 ` clshotwe at rockwellcollins.com
2013-09-04 23:09 ` [Buildroot] [PATCH 03/17] ustr: " Clayton Shotwell
2013-09-05 7:57 ` Thomas Petazzoni [this message]
2013-09-04 23:09 ` [Buildroot] [PATCH 04/17] libsemanage: " Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 05/17] checkpolicy: " Clayton Shotwell
2013-09-06 17:56 ` Thomas Petazzoni
2013-09-09 17:33 ` Clayton Shotwell
2013-09-11 16:44 ` Arnout Vandecappelle
2013-09-12 7:17 ` Thomas Petazzoni
2013-09-04 23:09 ` [Buildroot] [PATCH 06/17] sepolgen: " Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 07/17] setools: " Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 08/17] libcgroup: " Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 09/17] policycoreutils: " Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 10/17] python-pyxml: " Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 11/17] refpolicy: " Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 12/17] python-pyparsing: Add host build option Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 13/17] audit: new package Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 14/17] shadow: " Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 15/17] pcre: Add host build support Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 16/17] bzip2: Add host build shared library installation Clayton Shotwell
2013-09-04 23:09 ` [Buildroot] [PATCH 17/17] sqlite: Add host build support Clayton Shotwell
2013-09-06 17:49 ` [Buildroot] [PATCH 00/17] SELinux Buildroot Additions Thomas Petazzoni
2013-09-06 18:07 ` Ryan Barnett
2013-09-07 10:44 ` Thomas Petazzoni
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130905095749.25465b8e@skate \
--to=thomas.petazzoni@free-electrons.com \
--cc=buildroot@busybox.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.