From patchwork Wed Jul 8 12:05:35 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Florian Weimer X-Patchwork-Id: 39960 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id BC8043861843; Wed, 8 Jul 2020 12:05:43 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org BC8043861843 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1594209943; bh=q8A3rEzAZHN1ScD5aL6oX3MUZKxLbLqnV+l8gd7fHwM=; h=To:Subject:In-Reply-To:References:Date:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=WzlAhKDFmgFe2OyvB3vzEqVFgkSkh+OuOth2lMdwTR7o0UnRA5CexA3dGtw8fUi8e RADDYgPtTysEpxhbYQAgXSp7eMgxWgwMsXs3f3Ee7c7+fN67+XyUk6WrBRMZ5Kfz99 zzvul8Whc+2ou+QbCiXmVGqzsubs7HvNguW2YMxU= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from us-smtp-delivery-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by sourceware.org (Postfix) with ESMTP id 2DC8A3861024 for ; Wed, 8 Jul 2020 12:05:41 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 2DC8A3861024 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-436-IQziwwPeMM60taEJa4Oq2w-1; Wed, 08 Jul 2020 08:05:39 -0400 X-MC-Unique: IQziwwPeMM60taEJa4Oq2w-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 17E508015CE for ; Wed, 8 Jul 2020 12:05:38 +0000 (UTC) Received: from oldenburg2.str.redhat.com (ovpn-112-117.ams2.redhat.com [10.36.112.117]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 68E125C1B2 for ; Wed, 8 Jul 2020 12:05:37 +0000 (UTC) To: libc-alpha@sourceware.org Subject: [PATCH 1/3] Move non-deprecated RPC-related functions from sunrpc to inet In-Reply-To: References: X-From-Line: c961187637fc816341eadfee91df1f769ff020eb Mon Sep 17 00:00:00 2001 Message-Id: Date: Wed, 08 Jul 2020 14:05:35 +0200 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-Spam-Status: No, score=-13.2 required=5.0 tests=BAYES_00, DKIM_INVALID, DKIM_SIGNED, GIT_PATCH_0, KAM_DMARC_STATUS, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Florian Weimer via Libc-alpha From: Florian Weimer Reply-To: Florian Weimer Errors-To: libc-alpha-bounces@sourceware.org Sender: "Libc-alpha" This includes bindresvport and the NSS-related RPC functions. This will simplify the removal of the sunrpc functionality because these functions no longer have to be treated specially. --- inet/Makefile | 11 +++++++++-- sunrpc/bindrsvprt.c => inet/bindresvport.c | 0 {sunrpc => inet}/etc.rpc | 0 {sunrpc => inet}/getrpcbyname.c | 0 {sunrpc => inet}/getrpcbyname_r.c | 0 {sunrpc => inet}/getrpcbynumber.c | 0 {sunrpc => inet}/getrpcbynumber_r.c | 0 {sunrpc => inet}/getrpcent.c | 0 {sunrpc => inet}/getrpcent_r.c | 0 sunrpc/Makefile | 9 +-------- 10 files changed, 10 insertions(+), 10 deletions(-) rename sunrpc/bindrsvprt.c => inet/bindresvport.c (100%) rename {sunrpc => inet}/etc.rpc (100%) rename {sunrpc => inet}/getrpcbyname.c (100%) rename {sunrpc => inet}/getrpcbyname_r.c (100%) rename {sunrpc => inet}/getrpcbynumber.c (100%) rename {sunrpc => inet}/getrpcbynumber_r.c (100%) rename {sunrpc => inet}/getrpcent.c (100%) rename {sunrpc => inet}/getrpcent_r.c (100%) diff --git a/inet/Makefile b/inet/Makefile index bd2fc317b5..1ca06bba80 100644 --- a/inet/Makefile +++ b/inet/Makefile @@ -36,10 +36,11 @@ routines := htonl htons \ getnetbynm_r \ getproto getproto_r getprtent getprtent_r getprtname getprtname_r \ getsrvbynm getsrvbynm_r getsrvbypt getsrvbypt_r getservent \ - getservent_r \ + getservent_r getrpcent getrpcbyname getrpcbynumber \ + getrpcent_r getrpcbyname_r getrpcbynumber_r \ ether_aton ether_aton_r ether_hton ether_line \ ether_ntoa ether_ntoa_r ether_ntoh \ - rcmd rexec ruserpass \ + rcmd rexec ruserpass bindresvport \ getnetgrent_r getnetgrent \ getaliasent_r getaliasent getaliasname getaliasname_r \ in6_addr getnameinfo if_index ifaddrs inet6_option \ @@ -47,6 +48,8 @@ routines := htonl htons \ getsourcefilter setsourcefilter inet6_opt inet6_rth \ inet6_scopeid_pton deadline idna idna_name_classify +install-others = $(inst_sysconfdir)/rpc + aux := check_pf check_native ifreq tests := htontest test_ifindex tst-ntoa tst-ether_aton tst-network \ @@ -108,6 +111,10 @@ CFLAGS-tst-sockaddr.c += -fno-strict-aliasing endif +# Install the rpc database file. +$(inst_sysconfdir)/rpc: etc.rpc $(+force) + $(do-install) + ifeq ($(build-static-nss),yes) CFLAGS += -DSTATIC_NSS endif diff --git a/sunrpc/bindrsvprt.c b/inet/bindresvport.c similarity index 100% rename from sunrpc/bindrsvprt.c rename to inet/bindresvport.c diff --git a/sunrpc/etc.rpc b/inet/etc.rpc similarity index 100% rename from sunrpc/etc.rpc rename to inet/etc.rpc diff --git a/sunrpc/getrpcbyname.c b/inet/getrpcbyname.c similarity index 100% rename from sunrpc/getrpcbyname.c rename to inet/getrpcbyname.c diff --git a/sunrpc/getrpcbyname_r.c b/inet/getrpcbyname_r.c similarity index 100% rename from sunrpc/getrpcbyname_r.c rename to inet/getrpcbyname_r.c diff --git a/sunrpc/getrpcbynumber.c b/inet/getrpcbynumber.c similarity index 100% rename from sunrpc/getrpcbynumber.c rename to inet/getrpcbynumber.c diff --git a/sunrpc/getrpcbynumber_r.c b/inet/getrpcbynumber_r.c similarity index 100% rename from sunrpc/getrpcbynumber_r.c rename to inet/getrpcbynumber_r.c diff --git a/sunrpc/getrpcent.c b/inet/getrpcent.c similarity index 100% rename from sunrpc/getrpcent.c rename to inet/getrpcent.c diff --git a/sunrpc/getrpcent_r.c b/inet/getrpcent_r.c similarity index 100% rename from sunrpc/getrpcent_r.c rename to inet/getrpcent_r.c diff --git a/sunrpc/Makefile b/sunrpc/Makefile index d5840d0770..2d1861f3dc 100644 --- a/sunrpc/Makefile +++ b/sunrpc/Makefile @@ -32,7 +32,6 @@ include ../Makeconfig # file name limits: # # authunix_prot.c -> authuxprot.c -# bindresvport.c -> bindrsvprt.c # clnt_generic.c -> clnt_gen.c # clnt_perror.c -> clnt_perr.c # clnt_simple.c -> clnt_simp.c @@ -54,7 +53,6 @@ headers-sunrpc = $(addprefix rpc/,auth.h auth_unix.h clnt.h pmap_clnt.h \ key_prot.h) \ $(rpcsvc:%=rpcsvc/%) rpcsvc/bootparam.h headers = rpc/netdb.h -install-others = $(inst_sysconfdir)/rpc generated += $(rpcsvc:%.x=rpcsvc/%.h) $(rpcsvc:%.x=x%.c) $(rpcsvc:%.x=x%.stmp) \ $(rpcsvc:%.x=rpcsvc/%.stmp) rpcgen generated-dirs += rpcsvc @@ -70,13 +68,11 @@ need-export-routines := auth_des auth_unix clnt_gen clnt_perr clnt_tcp \ xdr_intXX_t xdr_mem xdr_ref xdr_sizeof xdr_stdio \ svc_run -routines := auth_none authuxprot bindrsvprt clnt_raw clnt_simp \ +routines := auth_none authuxprot clnt_raw clnt_simp \ rpc_dtable getrpcport pmap_clnt pm_getmaps pmap_prot pmap_prot2 \ pmap_rmt rpc_prot rpc_common rpc_cmsg svc_auth svc_authux svc_raw \ svc_simple xdr_float xdr_rec publickey authdes_prot \ des_crypt des_impl des_soft key_prot openchild rtime svcauth_des \ - getrpcent getrpcbyname getrpcbynumber \ - getrpcent_r getrpcbyname_r getrpcbynumber_r \ clnt_unix svc_unix create_xid $(need-export-routines) \ rpc_gethostbyname ifneq ($(link-obsolete-rpc),yes) @@ -188,9 +184,6 @@ include $(patsubst %,$(..)libof-iterator.mk,$(cpp-srcs-left)) # binary be the second dependency listed in each rule using rpcgen-cmd. rpcgen-cmd = CPP='$(CC) -E -x c-header' $(built-program-file) -Y ../scripts -# Install the rpc data base file. -$(inst_sysconfdir)/rpc: etc.rpc $(+force) - $(do-install) # Generate the rpcsvc headers with rpcgen. # We use a stamp file to avoid unnessary recompilation each time rpcgen is