[dpdk-dev,3/4] ether: rename version file to match library name

Message ID 20170831134244.35215-4-bruce.richardson@intel.com (mailing list archive)
State Accepted, archived
Headers

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

Bruce Richardson Aug. 31, 2017, 1:42 p.m. UTC
  While almost all libraries have the library name match the directory name,
some libraries and drivers do not. For those that don't, some have the
version filename use the libname, e.g. null_crypto, others have it use the
directory name, e.g. ether. Using the library name seems the better
standard to follow, so rename rte_ether_version.map to
rte_ethdev_version.map.

Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
---
 lib/librte_ether/Makefile                                          | 2 +-
 lib/librte_ether/{rte_ether_version.map => rte_ethdev_version.map} | 0
 2 files changed, 1 insertion(+), 1 deletion(-)
 rename lib/librte_ether/{rte_ether_version.map => rte_ethdev_version.map} (100%)
  

Comments

Ferruh Yigit Aug. 31, 2017, 2:18 p.m. UTC | #1
On 8/31/2017 2:42 PM, Bruce Richardson wrote:
> While almost all libraries have the library name match the directory name,
> some libraries and drivers do not. For those that don't, some have the
> version filename use the libname, e.g. null_crypto, others have it use the
> directory name, e.g. ether. Using the library name seems the better
> standard to follow, so rename rte_ether_version.map to
> rte_ethdev_version.map.
> 
> Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> ---
>  lib/librte_ether/Makefile                                          | 2 +-
>  lib/librte_ether/{rte_ether_version.map => rte_ethdev_version.map} | 0
>  2 files changed, 1 insertion(+), 1 deletion(-)
>  rename lib/librte_ether/{rte_ether_version.map => rte_ethdev_version.map} (100%)
> 
> diff --git a/lib/librte_ether/Makefile b/lib/librte_ether/Makefile
> index db692ae4d..27d9766a8 100644
> --- a/lib/librte_ether/Makefile
> +++ b/lib/librte_ether/Makefile
> @@ -39,7 +39,7 @@ LIB = librte_ethdev.a
>  CFLAGS += -O3
>  CFLAGS += $(WERROR_FLAGS)
>  
> -EXPORT_MAP := rte_ether_version.map
> +EXPORT_MAP := rte_ethdev_version.map

Why library name and folder name is different for ethdev, will it break
anything if folder also renamed to librte_ethdev? for consistency.

>  
>  LIBABIVER := 6
>  
> diff --git a/lib/librte_ether/rte_ether_version.map b/lib/librte_ether/rte_ethdev_version.map
> similarity index 100%
> rename from lib/librte_ether/rte_ether_version.map
> rename to lib/librte_ether/rte_ethdev_version.map
>
  
Bruce Richardson Aug. 31, 2017, 2:32 p.m. UTC | #2
On Thu, Aug 31, 2017 at 03:18:47PM +0100, Ferruh Yigit wrote:
> On 8/31/2017 2:42 PM, Bruce Richardson wrote:
> > While almost all libraries have the library name match the directory name,
> > some libraries and drivers do not. For those that don't, some have the
> > version filename use the libname, e.g. null_crypto, others have it use the
> > directory name, e.g. ether. Using the library name seems the better
> > standard to follow, so rename rte_ether_version.map to
> > rte_ethdev_version.map.
> > 
> > Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
> > ---
> >  lib/librte_ether/Makefile                                          | 2 +-
> >  lib/librte_ether/{rte_ether_version.map => rte_ethdev_version.map} | 0
> >  2 files changed, 1 insertion(+), 1 deletion(-)
> >  rename lib/librte_ether/{rte_ether_version.map => rte_ethdev_version.map} (100%)
> > 
> > diff --git a/lib/librte_ether/Makefile b/lib/librte_ether/Makefile
> > index db692ae4d..27d9766a8 100644
> > --- a/lib/librte_ether/Makefile
> > +++ b/lib/librte_ether/Makefile
> > @@ -39,7 +39,7 @@ LIB = librte_ethdev.a
> >  CFLAGS += -O3
> >  CFLAGS += $(WERROR_FLAGS)
> >  
> > -EXPORT_MAP := rte_ether_version.map
> > +EXPORT_MAP := rte_ethdev_version.map
> 
> Why library name and folder name is different for ethdev, will it break
> anything if folder also renamed to librte_ethdev? for consistency.
> 

Probably not, but it would be a much more visible change than just
changing the map filename, so I left it as-is for now. For the drivers,
there a quite a number of instances where the driver name is not going
to match the directory name, e.g  to include "crypto" or "event" for
clarity in the resulting library name. Because of that, I'm adding
support for allowing drivers to specify their name independently of the
directory name, and for consistency, I'm going to allow doing so for
libs too, since I want both drivers and libs to take more-or-less the
same set of parameters in their build files.

That said, no objection to a more comprehensive patch to rename the
folder. :-)

/Bruce
  

Patch

diff --git a/lib/librte_ether/Makefile b/lib/librte_ether/Makefile
index db692ae4d..27d9766a8 100644
--- a/lib/librte_ether/Makefile
+++ b/lib/librte_ether/Makefile
@@ -39,7 +39,7 @@  LIB = librte_ethdev.a
 CFLAGS += -O3
 CFLAGS += $(WERROR_FLAGS)
 
-EXPORT_MAP := rte_ether_version.map
+EXPORT_MAP := rte_ethdev_version.map
 
 LIBABIVER := 6
 
diff --git a/lib/librte_ether/rte_ether_version.map b/lib/librte_ether/rte_ethdev_version.map
similarity index 100%
rename from lib/librte_ether/rte_ether_version.map
rename to lib/librte_ether/rte_ethdev_version.map