Skip to contentSkip to conversation

rapidjson: Allow empty package

PATCH Superseded Joshua Watt 3 participants 5 messages Oct 23, 2018 – Nov 2, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 rapidjson: Allow empty package

Causes the empty base package to be created so that RapidJSON can be sanely included in an SDK via IMAGE_INSTALL, RDEPENDS, and the like.

---
 meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb | 1 +
 1 file changed, 1 insertion(+)
meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb +1 -0
index 8ab35d224..76e01f824 100644
@@ -19,6 +19,7 @@ inherit cmake
 EXTRA_OECMAKE += "-DRAPIDJSON_BUILD_DOC=OFF -DRAPIDJSON_BUILD_TESTS=OFF -DRAPIDJSON_BUILD_EXAMPLES=OFF"
 
 # RapidJSON is a header-only C++ library, so the main package will be empty.
+ALLOW_EMPTY_${PN} = "1"
 
 FILES_${PN}-dev += "${libdir}/cmake"
 RDEPENDS_${PN}-dev = ""
Signature · 1 line
2.17.1
#1 lore raw

Why is installing useless empty packages sane?

Quoted 32 lines · Joshua Watt

Causes the empty base package to be created so that RapidJSON can be sanely included in an SDK via IMAGE_INSTALL, RDEPENDS, and the like.

---
 meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb | 1 +
 1 file changed, 1 insertion(+)
meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb +0 -1
index 8ab35d224..76e01f824 100644
@@ -19,6 +19,7 @@ inherit cmake
 EXTRA_OECMAKE += "-DRAPIDJSON_BUILD_DOC=OFF -DRAPIDJSON_BUILD_TESTS=OFF
-DRAPIDJSON_BUILD_EXAMPLES=OFF"
 
 # RapidJSON is a header-only C++ library, so the main package will be

empty.
+ALLOW_EMPTY_${PN} = "1"

FILES_${PN}-dev += "${libdir}/cmake"
RDEPENDS_${PN}-dev = ""
--
2.17.1

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

#2 lore raw
Quoted 1 line · Martin Jansa

Why is installing useless empty packages sane?

The development packages that get installed in the SDK are picked up grabbing the -dev that corresponds to each ${PN} being installed. However, you can't do that with RapidJSON as there is no ${PN} package because it is empty and therefore culled. Adding the empty ${PN} package seems to be a pretty low-risk way of making RapidJSON behave like all the other packages when it comes to building into an SDK; effectively, IMAGE_INSTALL += "rapidjson" is now sufficient to get it in the SDK.
You could of course manually add "rapidjson-dev" to TOOLCHAIN_HOST_TASK, but that doesn't seem to be the precedent. This change is similar to those found in other header-only and staticdev- only recipes like libatomic-ops, gtest, libsrtp, tclap, ceres-solver, asio, and libinih.

Quoted 53 lines
Quoted 51 lines · Joshua Watt

Causes the empty base package to be created so that RapidJSON can be

sanely included in an SDK via IMAGE_INSTALL, RDEPENDS, and the like.

---

 meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb | 1 +
 1 file changed, 1 insertion(+)
meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb +0 -0

index 8ab35d224..76e01f824 100644

--- a/meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb

+++ b/meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb

meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb +0 -1
@@ -19,6 +19,7 @@ inherit cmake
 
 EXTRA_OECMAKE += "-DRAPIDJSON_BUILD_DOC=OFF
-DRAPIDJSON_BUILD_TESTS=OFF -DRAPIDJSON_BUILD_EXAMPLES=OFF"
 
 
 
 # RapidJSON is a header-only C++ library, so the main package will

be empty.

+ALLOW_EMPTY_${PN} = "1"

FILES_${PN}-dev += "${libdir}/cmake"

RDEPENDS_${PN}-dev = ""

Signature · 1 line
2.17.1
Signature · 119 lines
Joshua Watt <[email protected]>
From [email protected]  Tue Oct 23 22:32:22 2018
Return-Path: <[email protected]>
X-Original-To: [email protected]
Delivered-To: [email protected]
Received: from mail-pg1-f194.google.com (mail-pg1-f194.google.com
	[209.85.215.194])
	by mail.openembedded.org (Postfix) with ESMTP id 6025779AF6
	for <[email protected]>;
	Tue, 23 Oct 2018 22:32:22 +0000 (UTC)
Received: by mail-pg1-f194.google.com with SMTP id 32-v6so1340373pgu.2
	for <[email protected]>;
	Tue, 23 Oct 2018 15:32:23 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
	h=subject:to:cc:references:from:openpgp:autocrypt:message-id:date
	:user-agent:mime-version:in-reply-to:content-transfer-encoding
	:content-language;
	bh=Y+NWbuJtFbCiXXwhcn0qdxfC3N8oM3y+j5gtftufbE0=;
	b=NG9hfZKUQyXSOLQl8MaA+7LdBjz1BAnnJLEtgCrzfycSignVMi5VV4d2g58bojSNYn
	gg59o7QDBIUSGl3sr7TMOlkmK/VhlHfM8UHnjtiAln5dwHP0fzCP4hpLO6+vHPlbSQAN
	/w7tR6Ll3kRweUycKfYzyLUW/BV95e68dGwYQhOeDqKZ3pqOEreBT91yjJCK79l1M3jP
	C6k0cHZn7oir5qw6Q4YfMKa0DAGdJ6NtGcTGcs6KZt0fwH/5Si6UpPa0LD2WNW+LoZfj
	OUWwsoc5FrKRK1t7FAqOYx2Fla4HWx9HMOZa2W4/ddKETTYsUAu/xLK6Ejp8kgZlmTd7
	osLA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
	d=1e100.net; s=20161025;
	h=x-gm-message-state:subject:to:cc:references:from:openpgp:autocrypt
	:message-id:date:user-agent:mime-version:in-reply-to
	:content-transfer-encoding:content-language;
	bh=Y+NWbuJtFbCiXXwhcn0qdxfC3N8oM3y+j5gtftufbE0=;
	b=s7sbJsb0An9T3u13sryJWl1aUQJJA8DVTdyKSlcbVq0IoNSr+3hpJN8q9FCBBbYM7a
	efyBmp0b3vIj+k8bE3A2vsQP+IjCh/FYgYTnti7bEHh+typH/F5r8shQ4psf255NP1zA
	F9Fg5HBFM2rJf7SdGT6j4fM2FZBYrWaD/3v0+dyH/i6VZjZDNjAsfxqNRr9jYa4yopt0
	FsPQQ8i+LDMlDagrejSMA2a1zn40aMejaqeaMZp3DRf+VUJlOSxVI51ReFee9Ps+MrC8
	qaCsg1OBMilJX78jozKn+GiNdq/hgB2aUG6RfFrTIMzekLFb//lIuhXbbGgT5bZbI6B5
	6CEQ==
X-Gm-Message-State: AGRZ1gJ3nnq3OeOdr1SOZE8SfaG8VYeUDQ5fLmRgVoNGkxEfnXHFzZoL
	c97ix22oMQxkNap2Gw1SM/U=
X-Google-Smtp-Source: AJdET5eqNyJlIC5+x1cTJPRCpJiDbdVTfn1qCpuwgLEs5XA4iIVoVpWfRVq/bALuz/oloYbN26c2xw==
X-Received: by 2002:a63:fa4e:: with SMTP id g14-v6mr157013pgk.18.1540333943184;
	Tue, 23 Oct 2018 15:32:23 -0700 (PDT)
Received: from [10.15.240.186] ([109.144.222.79])
	by smtp.gmail.com with ESMTPSA id
	62-v6sm3078749pgc.58.2018.10.23.15.32.21
	(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
	Tue, 23 Oct 2018 15:32:22 -0700 (PDT)
To: Joshua Watt <[email protected]>,
	[email protected]
References: <[email protected]>
From: akuster808 <[email protected]>
Openpgp: preference=signencrypt
Autocrypt: [email protected]; prefer-encrypt=mutual; keydata=
	xsFNBFnlUP4BEADpKf+FQdLykenQXKk8i6xJNxDow+ypFeVAy8iFJp7Dsev+BtwUFo8VG7hx
	Jmd71vHMw+coBetWC3lk+IKjX815Ox0puYXQVRRtI+yMCgd6ib3oGxoQ8tCMwhf9c9/aKjaz
	mP97lWgGHbiEVsDpjzmMZGlJ6pDVZzxykkJExKaosE46AcA8KvfhRQg5zRyYBtinzs8Zu8AP
	aquZVHNXxPwjKPaSEEYqQjFeiNgFTavV+AhM2dmPmGUWCX9RZisrqA4slGwEB0srMdFf12Zg
	mD35Y9jZ80qpu5LPtJCFcsaAlebqR+dg36pIpiRR+olhN1wmC6LYP1vw6uMEYBjkTa2Rnb6+
	C4FDzCJD4UCrUvLMNeTW810DY0bjMMj3SfmSGSfQUssaaaTXCVlLGuGxyCr/kza1rHaX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pspyf6sUuSEi0WrlSxoLAr6p
	JG8rTUErYNeXe6JCdL31odDx1Dh5sdKIj2RicUYZNilxu9f1M7jZwf2ra1FGAlKj2ybqmgpZ
	EFteaiCinEYsvDyZyOiWHjAFI+RZIPQQL3AnVp4l7wYD3r9hnqYPww0slyMDcb9262RoFkHq
	dDwxPYarrNjWUpOzxB6bFxOgNRdCTgvQl8Ftk8a/yXB6vHeUSm1vPFCBxQPZytyfOLhEWm0J
	/mkVL0Z6iRK3p1LKnpLYCS4/esL2u7RrhPyCs2SsL58YcQF/g+PpeT9geZ+oyZ/4IQ+TWJoU
	PNHndk8VBTpzrmOaJxrebNL/W6C8JCmbLM11TAUMmHYi9JDytN8Au78hWpDbIdKwg1LeSxpw
	ZZD/OqOc0DBvHOpQhzkSrtR1lVlDV/+9E8J1T4uDhrGmZwYV+4xQetypHax8aAHisYbjXdVa
	8CS2NxU=
Message-ID: <[email protected]>
Date: Tue, 23 Oct 2018 23:32:19 +0100
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101
	Thunderbird/60.2.1
MIME-Version: 1.0
In-Reply-To: <[email protected]>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
Content-Language: en-US
Cc: Veselin Georgiev <[email protected]>
Subject: Re: [oe] [meta-oe][master][sumo][PATCH] rapidjson: Update to newer
 1.1.0 + git
X-BeenThere: [email protected]
X-Mailman-Version: 2.1.12
Precedence: list
List-Id: Using the OpenEmbedded metadata to build Distributions
	<openembedded-devel.lists.openembedded.org>
List-Unsubscribe: <http://lists.openembedded.org/mailman/options/openembedded-devel>,
	<mailto:[email protected]?subject=unsubscribe>
List-Archive: <http://lists.openembedded.org/pipermail/openembedded-devel/>
List-Post: <mailto:[email protected]>
List-Help: <mailto:[email protected]?subject=help>
List-Subscribe: <http://lists.openembedded.org/mailman/listinfo/openembedded-devel>,
	<mailto:[email protected]?subject=subscribe>
X-List-Received-Date: Tue, 23 Oct 2018 22:32:22 -0000
Quoted 3 lines · Joshua Watt

Bring in a newer version of rapidjson which includes a fixes when running on ARM, specifically 748a652f04 ("Fix SIGBUS due to unaligned access")

Master can do what it want bug Stable has many concerns. What version was the old hash?  How many changes between the two versions? Is this a bug fix only update? Did you build it on all arches and with musl too?

- armin

Quoted 29 lines

Also remove the existing patch file as the issue was resolved in the mainline by 4c9a28a28e ("CMake: do not pass -march=native or -mcpu=native when crosscompiling")

---
 meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb +2 -4
index 76e01f824..ec3df8263 100644
@@ -4,11 +4,9 @@ SECTION = "libs"
 LICENSE = "MIT"
 LIC_FILES_CHKSUM = "file://license.txt;md5=ba04aa8f65de1396a7e59d1d746c2125"
 
-SRC_URI = "git://github.com/miloyip/rapidjson.git;nobranch=1 \
-           file://remove-march-native-from-CMAKE_CXX_FLAGS.patch \
-"
+SRC_URI = "git://github.com/miloyip/rapidjson.git;nobranch=1"
 
-SRCREV = "e5635fb27feab7f6e8d7b916aa20ad799045a641"
+SRCREV = "6a905f9311f82d306da77bd963ec5aa5da07da9c"
 
 PV = "1.1.0+git${SRCPV}"
 
#3 lore raw
Quoted 4 lines · Joshua Watt
Quoted 1 line · Martin Jansa

Why is installing useless empty packages sane?

Quoted 13 lines

The development packages that get installed in the SDK are picked up grabbing the -dev that corresponds to each ${PN} being installed. However, you can't do that with RapidJSON as there is no ${PN} package because it is empty and therefore culled. Adding the empty ${PN} package seems to be a pretty low-risk way of making RapidJSON behave like all the other packages when it comes to building into an SDK; effectively, IMAGE_INSTALL += "rapidjson" is now sufficient to get it in the SDK.
You could of course manually add "rapidjson-dev" to TOOLCHAIN_HOST_TASK, but that doesn't seem to be the precedent. This change is similar to those found in other header-only and staticdev- only recipes like libatomic-ops, gtest, libsrtp, tclap, ceres-solver, asio, and libinih.

we also have
RDEPENDS_${PN}-dev = ""

so we need to remove that if this is to be added.

Quoted 60 lines
Quoted 45 lines
Quoted 43 lines · Joshua Watt

Causes the empty base package to be created so that RapidJSON can be

sanely included in an SDK via IMAGE_INSTALL, RDEPENDS, and the like.

---

 meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb | 1 +
 1 file changed, 1 insertion(+)
meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb +0 -0

index 8ab35d224..76e01f824 100644

--- a/meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb

+++ b/meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb

meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb +0 -1
@@ -19,6 +19,7 @@ inherit cmake
 
 EXTRA_OECMAKE += "-DRAPIDJSON_BUILD_DOC=OFF
-DRAPIDJSON_BUILD_TESTS=OFF -DRAPIDJSON_BUILD_EXAMPLES=OFF"
 
 
 
 # RapidJSON is a header-only C++ library, so the main package will

be empty.

+ALLOW_EMPTY_${PN} = "1"

FILES_${PN}-dev += "${libdir}/cmake"

Quoted 8 lines
Quoted 8 lines

RDEPENDS_${PN}-dev = ""

--

2.17.1

--
Joshua Watt <[email protected]>
--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

#4 lore raw

PATCH v2 1/1 rapidjson: Allow empty package

In reply to Joshua Watt

Causes the empty base package to be created so that RapidJSON can be sanely included in an SDK via IMAGE_INSTALL, RDEPENDS, and the like.

---
 meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta-oe/recipes-devtools/rapidjson/rapidjson_git.bb +1 -1
index cd18149504..c90eab043b 100644
@@ -18,6 +18,6 @@ EXTRA_OECMAKE += "-DRAPIDJSON_BUILD_DOC=OFF -DRAPIDJSON_BUILD_TESTS=OFF -DRAPIDJ
 
 # RapidJSON is a header-only C++ library, so the main package will be empty.
 
-RDEPENDS_${PN}-dev = ""
+ALLOW_EMPTY_${PN} = "1"
 
 BBCLASSEXTEND = "native nativesdk"
Signature · 1 line
2.19.1