Received: by 2002:ab2:7855:0:b0:1f9:5764:f03e with SMTP id m21csp47396lqp; Tue, 21 May 2024 18:00:22 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVB4nNx2D8cye+KAQlJuu8frPvHAfalLH0+L9Z8vT4XXB6J272xLDj2nljaK1EkytJLGIqosq1nMRi97EaT5TsVH/9FWicY8qQn8kBAhg== X-Google-Smtp-Source: AGHT+IGsBmyAo2gbR8lKw8KzkQqFIyDh1C3CZhZzZZxaRTn0Ei3dq1Hzd6ED13vsrJ1LZSsoET++ X-Received: by 2002:a05:6870:9721:b0:24c:4fcc:9011 with SMTP id 586e51a60fabf-24c68adfa8emr831405fac.19.1716339622142; Tue, 21 May 2024 18:00:22 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716339622; cv=pass; d=google.com; s=arc-20160816; b=LCcgr01J+96DL4X9XzJ9URohRFQ22YjH53mNlunboMdUhn7sCvNiqgVH2qt1uu0GOB QHRxprXEFJ2rgNJkuKQVsdav3jSlOEGwSU3FmBgkPuC13hJYK0aYdv8CGKUsCSQ873l1 OHPnd8PzTl/lGyPYrupo4bQDKILk2qXGask7vp53I7f2Z4JvpH67NCdpKVgVMOKHX8ij fAwn6hUXd+pJzeSWEdDTiZ4zo+El6kM5HtJaTk12ENgAm/EE7eq64CJRsN89Le9TR6AR 3wYw0td/icXy7mhZprEnkb+A1R/l6aE5U1hvCXG5l6ZhJvdaWmemM6giC9J9RMTaO2pe RjfQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:from:subject:message-id:references:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:in-reply-to:date :dkim-signature; bh=iZfRAHT6JEYkQgkQi9RSt0VBBFkg9g20KHoFp+lD64Q=; fh=Ax1HXQm2KYc9HaqsqRz+i063hVvcWbsER7iSkypzfug=; b=eMDpqI3wVpWWik0N7zBx/3Y7Eu4JFpcK22srwupinAkg2611LOx+w2lsUOVB+xbT0A 6IhQfXQknItplVoD3oihiqdUyRbus19w191q2zHy4u1xuFgg9W/lWDvDwBq7OZPY1c12 03X8lCtStJ0jxHTu/uyolNoY8QTPWQ6G8u1ZDaCNq2F6Ka2L4/k7y0vtbdhlPDrpOXRQ 4D21NYNYZScX2uYLJ8higeNEqVBhUp0gMuyKIkmFd8X9vWIcjQVQv9BEI3v+4FhpHqLW 67foK6O8QjK9MECVU2gC2h57QGexnl/nj33im52cCfxzA0O6RdbM6LHaJfbSyJlwaXhM 8LYw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=nfBM09op; arc=pass (i=1 spf=pass spfdomain=flex--edliaw.bounces.google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-185576-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-185576-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id d2e1a72fcca58-6f4d2aeee92si2562489b3a.169.2024.05.21.18.00.21 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 May 2024 18:00:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-185576-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=nfBM09op; arc=pass (i=1 spf=pass spfdomain=flex--edliaw.bounces.google.com dkim=pass dkdomain=google.com dmarc=pass fromdomain=google.com); spf=pass (google.com: domain of linux-kernel+bounces-185576-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-185576-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 8897AB23664 for ; Wed, 22 May 2024 01:00:07 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 20F83DF6C; Wed, 22 May 2024 00:59:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="nfBM09op" Received: from mail-yb1-f202.google.com (mail-yb1-f202.google.com [209.85.219.202]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7600D4A35 for ; Wed, 22 May 2024 00:59:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.219.202 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716339572; cv=none; b=O0IEsMeZX/Alyyvnfr86QzchKsn8vokVRZAO5ZrW2EsR6Y+fFvX0lpCC6XCCN8D6Ei3IaYAPjhhOZ0QR94iDYw6i3N33e8vCsxZo0PhSs8jrfFaE6/as3NiEkJ42WELOWYmWMJVSorsSAGu+r52nA8fmq+JCePJGgeOmGgCVf4c= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716339572; c=relaxed/simple; bh=aZVHm0DBgwBFcctm+iRf2rlUq1vypMjcU0HhukUAAQo=; h=Date:In-Reply-To:Mime-Version:References:Message-ID:Subject:From: To:Cc:Content-Type; b=USRB/rMk2VdBeDxIlXGXO+hkIzNSJaIifqIjKojscSmvTvg96MRYPaPMV99wcsgqvHaVaL6rw5wafd+abL2kp1WDmaQxfLjV8a06HZLC2GfLuFqnrr1KPsEWjka1Z8J6/Wj8xEXPx39a0q2X3lVY5S/ofx9CYJkz36gvQmgjSwU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--edliaw.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=nfBM09op; arc=none smtp.client-ip=209.85.219.202 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--edliaw.bounces.google.com Received: by mail-yb1-f202.google.com with SMTP id 3f1490d57ef6-dc743cc50a6so18108988276.2 for ; Tue, 21 May 2024 17:59:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1716339568; x=1716944368; darn=vger.kernel.org; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:from:to:cc:subject:date:message-id:reply-to; bh=iZfRAHT6JEYkQgkQi9RSt0VBBFkg9g20KHoFp+lD64Q=; b=nfBM09opQPdrL1s6/+dgUWVw8LeegKq2F0gVdFOSAWybIZJIs8PRtHEqiTI7fY8V4p wKqQ0va/ZuP9rGE/l4rjXu4jWr3gm4gRNBomU3kbvpcFahQIwkg/l9dXwIVX8n+gB0VJ fDUiiIvdPCYqoYE2JKuvCJl35HDNsqb5I9FVmgqBtxDbmt5W9AGKTsuNdghwXKNoR9EH 9AymOOgbdy5Ufsol9iT+z/XlkPQgRTtS8B38TGRbGY2OxLtKHiEGyI6LFZ+qPGlYrctO u4nddiqrGUfdYEJkgKBYOF0XcBv5oFNCxOrOrTQjFbKaH8lzyixxYFDdc7EHMn89r5KK epVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716339568; x=1716944368; h=cc:to:from:subject:message-id:references:mime-version:in-reply-to :date:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=iZfRAHT6JEYkQgkQi9RSt0VBBFkg9g20KHoFp+lD64Q=; b=r/eivTSpq/aB9MNsDAzZn9U2vXS4B4w8xYJsszZR4TXyzMQD5mwUQxEOTC5sJ8oJyq 7/UhVccfeG4qkQACN6vSZUVMoKy7RBAOouFtO9k89SV0QfEPv7egrBOmM/qDNPqOn2D8 nWZKOKI5yaYd3QVZMAQmrFsjh9xDIZEn4jtRFYnl5+gmbmykFOK/sNzLimKmWm6mGYNw xo3gUrIog8LW9WZl9glD4WeKL8vJnxuJiGJLb7pXr+edJ5J8n9yN1KP8v5qn77c4O3uf l1Lt/PLyy0mpmV5Z6TWcRV0IphMwJuD2nR69Y4cGzYCd3gIum8w2TCQGMyEFAuV2405O tT0g== X-Gm-Message-State: AOJu0YxPuF5wVi+DeFQs8bOdj63K5i3PESnIRpYe8wi4hMVk/nkmrIkZ 72speuzTDTg6CsDj67PauMsC1nRKg3SqTbod5pnj3lJYljMPyXUV9BmdTiytHGoth2dDsisoVc/ d/Q== X-Received: from edliaw.c.googlers.com ([fda3:e722:ac3:cc00:24:72f4:c0a8:305d]) (user=edliaw job=sendgmr) by 2002:a05:6902:70a:b0:df4:628c:3045 with SMTP id 3f1490d57ef6-df4e0e130ebmr75748276.8.1716339568433; Tue, 21 May 2024 17:59:28 -0700 (PDT) Date: Wed, 22 May 2024 00:56:47 +0000 In-Reply-To: <20240522005913.3540131-1-edliaw@google.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 References: <20240522005913.3540131-1-edliaw@google.com> X-Mailer: git-send-email 2.45.1.288.g0e0cd299f1-goog Message-ID: <20240522005913.3540131-2-edliaw@google.com> Subject: [PATCH v5 01/68] selftests: Compile with -D_GNU_SOURCE when including lib.mk From: Edward Liaw To: shuah@kernel.org, "=?UTF-8?q?Micka=C3=ABl=20Sala=C3=BCn?=" , "=?UTF-8?q?G=C3=BCnther=20Noack?=" , Christian Brauner , Richard Cochran , Paul Walmsley , Palmer Dabbelt , Albert Ou , Alexei Starovoitov , Daniel Borkmann , "David S. Miller" , Jakub Kicinski , Jesper Dangaard Brouer , John Fastabend Cc: linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, kernel-team@android.com, Edward Liaw , linux-security-module@vger.kernel.org, netdev@vger.kernel.org, linux-riscv@lists.infradead.org, bpf@vger.kernel.org, John Hubbard Content-Type: text/plain; charset="UTF-8" lib.mk will add -D_GNU_SOURCE to CFLAGS by default. This will make it unnecessary to add #define _GNU_SOURCE in the source code. Suggested-by: John Hubbard Signed-off-by: Edward Liaw --- tools/testing/selftests/lib.mk | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/testing/selftests/lib.mk b/tools/testing/selftests/lib.mk index 429535816dbd..e782f4c96aee 100644 --- a/tools/testing/selftests/lib.mk +++ b/tools/testing/selftests/lib.mk @@ -188,6 +188,9 @@ endef clean: $(if $(TEST_GEN_MODS_DIR),clean_mods_dir) $(CLEAN) +# Build with _GNU_SOURCE by default +CFLAGS += -D_GNU_SOURCE + # Enables to extend CFLAGS and LDFLAGS from command line, e.g. # make USERCFLAGS=-Werror USERLDFLAGS=-static CFLAGS += $(USERCFLAGS) -- 2.45.1.288.g0e0cd299f1-goog