Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp6228024ybe; Tue, 17 Sep 2019 23:22:12 -0700 (PDT) X-Google-Smtp-Source: APXvYqwK6OABQV8fwGuI4YHBO9uMWziktfQ73KeG7Hf+9rWsRPh2TKZE26RftQ/YV0EZXTBC7wqE X-Received: by 2002:a17:906:15c2:: with SMTP id l2mr8045143ejd.4.1568787731978; Tue, 17 Sep 2019 23:22:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1568787731; cv=none; d=google.com; s=arc-20160816; b=Q/wBXXgOfgSmeYDZ2Sh6oQdw8UDqxe/fuYoG2F2IXfxopQu88Omrr5qJTM8RBO6tgL V9EPJ6kbdKYnY43jKutAWz5YFcPTqqtE1NNPGtb3Vrkaif079QMDxnKN07RnUrgkW2VI Fn7CxwCwdewecRoZ5iRpVHhRXfeOGhLM8gf4y9cuudxv4jLX4WG7vI1pMhTeIlAMO+10 LOv2fE13OAC4bIvmtvebayqes8OJ71YGQebWvfbJzGFg8brAsiqm1kM71pXkb1dwozIu t7gOZ++bgXWYojZQ3EGI2cWVicmKFtPZAVulTlOdjEvKwOFSxqf0oKYcvqitLYWMoZMe oRTA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=P2KTni67QeY65KHrP8GaDvnakNrehjhBO4czvpB338c=; b=dx6VhJuPbLncX7yI2xjstmEKQBPbUbKuzecunyfD+iymYqGhVfEcN5mbczbdvdzSjY wM5hgaIMCoNRJA5xAsy5McSDo/+s7XV+g50Pja7C3TAUgPpJpQFfuMBKMumNselWGA/P xHAQBDqsvqfgmPJFLRjISFave3D3VliOdmn4sAX7mVCNf1m1JuCRkpZyx3kRUCpnfBGo iZnXtaeNkrJ/cmlplHpwH1yy6lfQsDCPLTjT4qXC8SDTVbrEKxQZ0MZ7gYJ4Lb4lbcfZ vIXJXkLUehRhbzsKB6JxysIuSxbVu7mm2NrF0Kaez4RMZwYYY7FDN7yVl4zYLQKbfruR YhYA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=B7CIqFuM; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id kt5si2322780ejb.283.2019.09.17.23.21.49; Tue, 17 Sep 2019 23:22:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=B7CIqFuM; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727846AbfIRFeE (ORCPT + 99 others); Wed, 18 Sep 2019 01:34:04 -0400 Received: from mail-qk1-f195.google.com ([209.85.222.195]:37598 "EHLO mail-qk1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727152AbfIRFeD (ORCPT ); Wed, 18 Sep 2019 01:34:03 -0400 Received: by mail-qk1-f195.google.com with SMTP id u184so6760971qkd.4; Tue, 17 Sep 2019 22:34:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=P2KTni67QeY65KHrP8GaDvnakNrehjhBO4czvpB338c=; b=B7CIqFuM8ETsZhGVqNQ1XsZXtm3fq3qmbF59nybqfWLI0FHkTtCdYNcsiU/l05Qt8S zOMGPMXWOILvyxb+Us0Zv6uZc+YOo+k1oeG2N4OViCmEjMeIu9SGmcbC2M9mXnCG4pxL Kny1RH+pr5PTZi+01X+xr/tR/nWHqnAoT+P5d8euEpLPPwEB2o2tuFSDM0OgVQ7rWBJ1 aAUTwoBca0mOuu5Rt29zTw1hhYEcs7P+Lku0yIuEsLI2fHAkRCCdZI77N4b8LmKUPdm0 M2Pwv/yjBODbibtiElZrsGWeerNf0LXDk2uUuXeNeRuTHmoEa9NRYHcnxEgiRIh3xUHA P3EA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=P2KTni67QeY65KHrP8GaDvnakNrehjhBO4czvpB338c=; b=mGMRaCGmz0TO2Oa1oLPExRrwf+T0qAJEnxRZhQbFH0aTqQHrIH4I+0SOwjg0kjts6E 4NGY1KPdpiHJkWQRl3iZrbi3kYpdySCTItZm0m3kMdLLiQkMBfIgZ54JYejVo9J9E354 ICFWRe7uveRQ3ffb+uNFUu8yps7LsAY5ja/e3neWfX34PLuoGb7/blmxuOaG6xto72nt LQe7MApNu8+rflMbnEGbIBYjym6YUpBqfxMAhNcSwn+n8Z2jjbLi1koHoxkiQ0EDh2Bh gnUXSJPrD2XqPZNNDjBY2B6zKImsWDfI4MDlagAhzaVTD9CkjXkWnEXFBsHfpYZlIzQL NXvw== X-Gm-Message-State: APjAAAXsCuH2UyYErXpkIM8nT/JckAH2G9Ykvb9K5qN43ML4z7DKYqZy ZAY95MmWc+KLy0CUGlKja425NozMxx7teX2eL7c= X-Received: by 2002:a37:4e55:: with SMTP id c82mr2257626qkb.437.1568784842596; Tue, 17 Sep 2019 22:34:02 -0700 (PDT) MIME-Version: 1.0 References: <20190916105433.11404-1-ivan.khoronzhuk@linaro.org> In-Reply-To: <20190916105433.11404-1-ivan.khoronzhuk@linaro.org> From: Andrii Nakryiko Date: Tue, 17 Sep 2019 22:33:51 -0700 Message-ID: Subject: Re: [PATCH v3 bpf-next 00/14] samples: bpf: improve/fix cross-compilation To: Ivan Khoronzhuk Cc: Alexei Starovoitov , Daniel Borkmann , Yonghong Song , "David S. Miller" , Jakub Kicinski , Jesper Dangaard Brouer , john fastabend , open list , Networking , bpf , clang-built-linux@googlegroups.com, sergei.shtylyov@cogentembedded.com Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Sep 16, 2019 at 4:02 AM Ivan Khoronzhuk wrote: > Thanks for these changes, they look good overall. It would be great if someone else could test and validate that cross-compilation works not just in your environment and generated binaries successfully run on target machines, though... [...] > > Ivan Khoronzhuk (14): > samples: bpf: makefile: fix HDR_PROBE "echo" > samples: bpf: makefile: fix cookie_uid_helper_example obj build > samples: bpf: makefile: use --target from cross-compile > samples: bpf: use own EXTRA_CFLAGS for clang commands > samples: bpf: makefile: use __LINUX_ARM_ARCH__ selector for arm > samples: bpf: makefile: drop unnecessarily inclusion for bpf_load > samples: bpf: add makefile.target for separate CC target build > samples: bpf: makefile: base target programs rules on Makefile.target > samples: bpf: makefile: use own flags but not host when cross compile > samples: bpf: makefile: use target CC environment for HDR_PROBE > libbpf: makefile: add C/CXX/LDFLAGS to libbpf.so and test_libpf > targets > samples: bpf: makefile: provide C/CXX/LD flags to libbpf > samples: bpf: makefile: add sysroot support > samples: bpf: README: add preparation steps and sysroot info > Prefixes like "samples: bpf: makefile: " are very verbose without adding much value. We've been converging to essentially this set of prefixes: - "libbpf:" for libbpf changes - "bpftool:" for bpftool changes - "selftests/bpf:" for bpf selftests - "samples/bpf:" for bpf samples There is no need to prefix with "makefile: " either. Please update your patch subjects in the next version. Thanks! > samples/bpf/Makefile | 179 +++++++++++++++++++++--------------- > samples/bpf/Makefile.target | 75 +++++++++++++++ > samples/bpf/README.rst | 41 ++++++++- > tools/lib/bpf/Makefile | 11 ++- > 4 files changed, 225 insertions(+), 81 deletions(-) > create mode 100644 samples/bpf/Makefile.target > > -- > 2.17.1 >