From patchwork Wed Nov 12 13:59:16 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yousong Zhou X-Patchwork-Id: 419617 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from arrakis.dune.hu (arrakis.dune.hu [78.24.191.176]) (using TLSv1.1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id C7FD51400A0 for ; Wed, 10 Dec 2014 23:19:10 +1100 (AEDT) Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id D9BE228C1D5; Wed, 10 Dec 2014 13:16:06 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on arrakis.dune.hu X-Spam-Level: X-Spam-Status: No, score=-0.3 required=5.0 tests=BAYES_00, DATE_IN_PAST_96_XX, FREEMAIL_FROM,T_DKIM_INVALID autolearn=no version=3.3.2 Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 86CA528C1D5 for ; Wed, 10 Dec 2014 13:16:01 +0100 (CET) X-policyd-weight: using cached result; rate: -8.5 Received: from mail-pd0-f169.google.com (mail-pd0-f169.google.com [209.85.192.169]) by arrakis.dune.hu (Postfix) with ESMTPS for ; Wed, 10 Dec 2014 13:16:01 +0100 (CET) Received: by mail-pd0-f169.google.com with SMTP id z10so2695850pdj.14 for ; Wed, 10 Dec 2014 04:17:43 -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:in-reply-to:references; bh=I8pSa95TvETzCeYAuV3isk9HuKuF/9N/lkvdMVvCBzo=; b=s8gWg8zGdHf1OqwDM5Zcssol/6ORARmH9D0KZ3tfP6QdDVb07HqKotMH7iico3kvjh RplXXK9JuTi7bVeYkPeul454DhoPqJUjMsJmYtDpDXHPLhPVNSOISD2vU3UHKZg3FOl3 KFx8hPXIQkUKOTaznKahe2iO86Ooz0gDB+3w9hJvbujxapQTJgb/a84vYMc48zadXote NgDyqP/xE8LddvESQaNiJrbpURQVa6Wf9O70VtSZvw1o/uUhIrVoph5glNwAQhG8VvSM a2p1yTAiF4Nvk1DrenI+iKgmF2jFAVah/S/clZ2ts+c5aesEXRtERJOTr3mityUSk00I Ov+Q== X-Received: by 10.69.20.74 with SMTP id ha10mr6633946pbd.122.1418213863116; Wed, 10 Dec 2014 04:17:43 -0800 (PST) Received: from debian.lan ([103.29.140.56]) by mx.google.com with ESMTPSA id hc10sm4063709pbd.78.2014.12.10.04.17.40 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 10 Dec 2014 04:17:42 -0800 (PST) From: Yousong Zhou To: nbd@openwrt.org Date: Wed, 12 Nov 2014 21:59:16 +0800 Message-Id: <1415800763-14311-4-git-send-email-yszhou4tech@gmail.com> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1415800763-14311-1-git-send-email-yszhou4tech@gmail.com> References: <1415800763-14311-1-git-send-email-yszhou4tech@gmail.com> Cc: openwrt-devel@lists.openwrt.org Subject: [OpenWrt-Devel] [PATCH v2 03/10] examples: fix build. X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: openwrt-devel-bounces@lists.openwrt.org Sender: "openwrt-devel" - runqueue-example.c: fix include path for in-tree build. - blobmsg-example.c: add inttypes.h for using PRIu64. - add examples/ subdirectory to main CMakeLists.txt Signed-off-by: Yousong Zhou --- CMakeLists.txt | 1 + examples/blobmsg-example.c | 1 + examples/runqueue-example.c | 2 +- 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 4b1570c..ddd5533 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -39,6 +39,7 @@ INSTALL(TARGETS ubox ubox-static ) ADD_SUBDIRECTORY(lua) +ADD_SUBDIRECTORY(examples) find_library(json NAMES json-c) IF(EXISTS ${json}) diff --git a/examples/blobmsg-example.c b/examples/blobmsg-example.c index 69ddce8..01b0518 100644 --- a/examples/blobmsg-example.c +++ b/examples/blobmsg-example.c @@ -1,4 +1,5 @@ #include +#include #include "blobmsg.h" #include "blobmsg_json.h" diff --git a/examples/runqueue-example.c b/examples/runqueue-example.c index 1ae184a..13ab864 100644 --- a/examples/runqueue-example.c +++ b/examples/runqueue-example.c @@ -16,11 +16,11 @@ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. */ -#include #include #include #include +#include "uloop.h" #include "runqueue.h" static struct runqueue q;