From patchwork Tue Sep 9 15:18:11 2025 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 274 Return-Path: X-Original-To: u-boot-concept@u-boot.org Delivered-To: u-boot-concept@u-boot.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1757431173; bh=blVju8Qt5ogKsRXECJfHuRn37lToYQPRFelcqq1z1H0=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=bYcPjG3iVRVEma3HJbDEjLZ7BpPGLIH8e4qMsOWtegHvpn2f2qgT73kz/LGHu7QUp Q9Pio2Y+IAjgCJ+XZSSxkxWTtKaIviS4+yhyCtkVksfaOqitrpcwUcErDmlNycSVbd oMj7DZyNXvPFDgw28DTI+UVxSW0rEy/rgowdXuhws/TMUDWqdhDU01bstHsiAr1bfq 0fwL5zKjylC9n9FW1H+uJVYLO8+Ii2toj08H6imvi2nqSapNwxnfGZz6PwBXUhzl0s 9DDmJHpfeqXQjLy/1ngyhLGlgpxz25RWCOqMKa5xdR4ekGXfusjHwbuogsmcbtnwEJ jsgq88f/JvznA== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 4AE1A679F7 for ; Tue, 9 Sep 2025 09:19:33 -0600 (MDT) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10024) with ESMTP id 5I0TUZR_HUV6 for ; Tue, 9 Sep 2025 09:19:33 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1757431173; bh=blVju8Qt5ogKsRXECJfHuRn37lToYQPRFelcqq1z1H0=; h=From:To:Date:In-Reply-To:References:CC:Subject:List-Id: List-Archive:List-Help:List-Owner:List-Post:List-Subscribe: List-Unsubscribe:From; b=bYcPjG3iVRVEma3HJbDEjLZ7BpPGLIH8e4qMsOWtegHvpn2f2qgT73kz/LGHu7QUp Q9Pio2Y+IAjgCJ+XZSSxkxWTtKaIviS4+yhyCtkVksfaOqitrpcwUcErDmlNycSVbd oMj7DZyNXvPFDgw28DTI+UVxSW0rEy/rgowdXuhws/TMUDWqdhDU01bstHsiAr1bfq 0fwL5zKjylC9n9FW1H+uJVYLO8+Ii2toj08H6imvi2nqSapNwxnfGZz6PwBXUhzl0s 9DDmJHpfeqXQjLy/1ngyhLGlgpxz25RWCOqMKa5xdR4ekGXfusjHwbuogsmcbtnwEJ jsgq88f/JvznA== Received: from mail.u-boot.org (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 381D4679D6 for ; Tue, 9 Sep 2025 09:19:33 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1757431170; bh=o/SKSa0/TOLgr4uVsFk7yXZuExbPNd0KAfqgAOJMkBg=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=UKgls5oy9mSKokXVXuuL8fmS5DjoDCI+EcpWhnC5Rw+0VzoSFsZAs9cHINFW5NFd3 Gak9IpX5hgrb8ilw7yypRto41MTXwXefHTRZ+i2rpwTqWo5t8C8CSUdyotyJa5sUDA xTufkNeSbTdZKufAyYJBBMurQ6ye5dXVE4op9X8H/zD1bI9kfL+BxtqdZYObgpgn9i Qs3RKdEckUEJW74/hApaPjAVYOH+G6iTKQbKaWzk4W/TnjT3w/IzDZimm1bZduUxN7 WEtCo5TrOR8wnQzQGsoZsYIak9ytlJCZuxyvz8y783YciCPaoM15mnDnQYtLjGw57y K2E3I76GPkWyQ== Received: from localhost (localhost [127.0.0.1]) by mail.u-boot.org (Postfix) with ESMTP id 9B4F360026; Tue, 9 Sep 2025 09:19:30 -0600 (MDT) X-Virus-Scanned: Debian amavis at Received: from mail.u-boot.org ([127.0.0.1]) by localhost (mail.u-boot.org [127.0.0.1]) (amavis, port 10026) with ESMTP id 9iKfhG40iYY7; Tue, 9 Sep 2025 09:19:30 -0600 (MDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=u-boot.org; s=default; t=1757431169; bh=GKWkdvCRe79XHBrZo2zoBq9V4O5gDOsUQXXVXzJcEgE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=uJKR6RWVjwyr5bS8Jmm19lcKvM+E+ylLBcEweVofwDCGEi00gT4swy+BG3gd9PIxS ZZfPu8kpZB0HJq7Xcdnr3neOYhi2xDPwgjou1piJ86vXqCoujfo/nLqbGORSnFiHss N9lzkrzhRw05YO+bbj+1iJjKh6Uc5T9KC5KyoHuu9vf7TYEKbJUsILuqmNVZb4xNc7 JB1K+ILS15a4XjuUQTBrqbAOnJab3nf0HUk/ahNwMzjcN+oYiXCS2Uru1vtUyJbF4E yFt9sx3h3jO1F/MLJUTrkVx7zXUSdSSBX78refVgIMYxtDtKCsN9S0Nd2apHmCgrNC en8nCIzW3tYdA== Received: from u-boot.org (unknown [73.34.74.121]) by mail.u-boot.org (Postfix) with ESMTPSA id 35940679D6; Tue, 9 Sep 2025 09:19:29 -0600 (MDT) From: Simon Glass To: U-Boot Concept Date: Tue, 9 Sep 2025 09:18:11 -0600 Message-ID: <20250909151824.2327219-15-sjg@u-boot.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20250909151824.2327219-1-sjg@u-boot.org> References: <20250909151824.2327219-1-sjg@u-boot.org> MIME-Version: 1.0 Message-ID-Hash: W4FWRT7OXHI4XAMJRM5M7TKLV566BZBG X-Message-ID-Hash: W4FWRT7OXHI4XAMJRM5M7TKLV566BZBG X-MailFrom: sjg@u-boot.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Heinrich Schuchardt , Simon Glass X-Mailman-Version: 3.3.10 Precedence: list Subject: [Concept] [PATCH 14/18] ulib: Makefile: Plumb in creation of the API header List-Id: Discussion and patches related to U-Boot Concept Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: From: Simon Glass Plumb in generation of the u-boot-api.h file, containing renamed symbols for inclusion by the program being linked with ulib. Signed-off-by: Simon Glass --- Makefile | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index f157de21008..c4a5dbea199 100644 --- a/Makefile +++ b/Makefile @@ -1902,6 +1902,16 @@ quiet_cmd_libu-boot.a = AR $@ libu-boot.a: .ulib-objs include/u-boot-api.h FORCE $(call if_changed,libu-boot.a) +# Generate API header with renamed function declarations +quiet_cmd_u-boot-api.h = APIH $@ + cmd_u-boot-api.h = $(PYTHON3) $(srctree)/scripts/build_api.py \ + $(srctree)/lib/ulib/rename.syms --api $@ \ + --include-dir $(srctree)/include + +include/u-boot-api.h: $(srctree)/lib/ulib/rename.syms \ + $(srctree)/scripts/build_api.py FORCE + $(call if_changed,u-boot-api.h) + # Build ulib_test that links with shared library quiet_cmd_ulib_test = HOSTCC $@ cmd_ulib_test = $(HOSTCC) $(HOSTCFLAGS) \ @@ -2343,7 +2353,8 @@ CLEAN_FILES += include/autoconf.mk* include/bmp_logo.h include/bmp_logo_data.h \ Test* capsule*.*.efi-capsule capsule*.map \ test/ulib/ulib_test test/ulib/ulib_test_static \ libu-boot.so.tmp libu-boot.so.objlist \ - libu-boot.a.tmp libu-boot.a.objlist + libu-boot.a.tmp libu-boot.a.objlist \ + include/u-boot-api.h # Directories & files removed with 'make mrproper' MRPROPER_DIRS += include/config include/generated spl tpl vpl \