mbox

libtirpc: change from package to common

Message ID 1466929388-15498-1-git-send-email-marcel.lorenz@ipfire.org
State Superseded
Headers

Message

Marcel Lorenz June 26, 2016, 6:23 p.m. UTC
  This patch changes the lib from a package to common
lsof 4.98 need this lib for working.
The lib are moved to /lib. This is the recommendation from:
http://www.linuxfromscratch.org/blfs/view/svn/basicnet/libtirpc.html

Signed-off-by: Marcel Lorenz <marcel.lorenz@ipfire.org>
---
 config/rootfiles/{packages => common}/libtirpc |  7 +++----
 lfs/libtirpc                                   | 21 ++++++++++-----------
 2 files changed, 13 insertions(+), 15 deletions(-)
 rename config/rootfiles/{packages => common}/libtirpc (95%)
  

Comments

Jonatan Schlag July 5, 2016, 7:26 p.m. UTC | #1
Hi,

Am So, 26. Jun, 2016 um 10:23 schrieb Marcel Lorenz 
<marcel.lorenz@ipfire.org>:
> This patch changes the lib from a package to common
> lsof 4.98 need this lib for working.
> The lib are moved to /lib. This is the recommendation from:
> http://www.linuxfromscratch.org/blfs/view/svn/basicnet/libtirpc.html
> 
> Signed-off-by: Marcel Lorenz <marcel.lorenz@ipfire.org>
> ---
>  config/rootfiles/{packages => common}/libtirpc |  7 +++----
>  lfs/libtirpc                                   | 21 
> ++++++++++-----------
>  2 files changed, 13 insertions(+), 15 deletions(-)
>  rename config/rootfiles/{packages => common}/libtirpc (95%)
> 
> diff --git a/config/rootfiles/packages/libtirpc 
> b/config/rootfiles/common/libtirpc
> similarity index 95%
> rename from config/rootfiles/packages/libtirpc
> rename to config/rootfiles/common/libtirpc
> index e197563..02cf846 100644
> --- a/config/rootfiles/packages/libtirpc
> +++ b/config/rootfiles/common/libtirpc
> @@ -1,4 +1,6 @@
>  etc/netconfig
> +lib/libtirpc.so.3
> +lib/libtirpc.so.3.0.0
>  #usr/include/tirpc
>  #usr/include/tirpc/netconfig.h
>  #usr/include/tirpc/rpc
> @@ -33,11 +35,8 @@ etc/netconfig
>  #usr/include/tirpc/rpcsvc
>  #usr/include/tirpc/rpcsvc/crypt.h
>  #usr/include/tirpc/rpcsvc/crypt.x
> -#usr/lib/libtirpc.a
>  #usr/lib/libtirpc.la
> -#usr/lib/libtirpc.so
> -usr/lib/libtirpc.so.3
> -usr/lib/libtirpc.so.3.0.0
> +usr/lib/libtirpc.so
>  #usr/lib/pkgconfig/libtirpc.pc
>  #usr/share/man/man3/bindresvport.3t
>  #usr/share/man/man3/des_crypt.3t
> diff --git a/lfs/libtirpc b/lfs/libtirpc
> index 382d7e5..65466d0 100644
> --- a/lfs/libtirpc
> +++ b/lfs/libtirpc
> @@ -1,7 +1,7 @@
>  
> ###############################################################################
>  #                                                                    
>          #
>  # IPFire.org - A linux based firewall                                
>          #
> -# Copyright (C) 2016 IPFire Team  <info@ipfire.org>                  
>          #
> +# Copyright (C) 2016  IPFire Team  <info@ipfire.org>                 
>          #
>  #                                                                    
>          #
>  # This program is free software: you can redistribute it and/or 
> modify        #
>  # it under the terms of the GNU General Public License as published 
> by        #
> @@ -31,10 +31,6 @@ DL_FILE    = $(THISAPP).tar.bz2
>  DL_FROM    = $(URL_IPFIRE)
>  DIR_APP    = $(DIR_SRC)/$(THISAPP)
>  TARGET     = $(DIR_INFO)/$(THISAPP)
> -PROG       = libtirpc
> -PAK_VER    = 1
> -
> -DEPS       = ""
> 
>  
> ###############################################################################
>  # Top-level Rules
> @@ -54,9 +50,6 @@ download :$(patsubst %,$(DIR_DL)/%,$(objects))
> 
>  md5 : $(subst %,%_MD5,$(objects))
> 
> -dist:
> -	@$(PAK)
> -
>  
> ###############################################################################
>  # Downloading, checking, md5sum
>  
> ###############################################################################
> @@ -76,9 +69,15 @@ $(subst %,%_MD5,$(objects)) :
> 
>  $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
>  	@$(PREBUILD)
> -	@rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar jxf $(DIR_DL)/$(DL_FILE)
> -	cd $(DIR_APP) && ./configure --prefix=/usr --sysconfdir=/etc 
> --disable-gssapi --disable-ipv6
> -	cd $(DIR_APP) && make $(MAKETUNING) $(EXTRA_MAKE)
> +	@rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
> +	cd $(DIR_APP) && ./configure --prefix=/usr \
> +			--sysconfdir=/etc \
> +			--disable-static \
> +			--disable-gssapi \
> +			--disable-ipv6
> +	cd $(DIR_APP) && make $(MAKETUNING)
>  	cd $(DIR_APP) && make install
> +	mv -v /usr/lib/libtirpc.so.* /lib
> +	ln -sfv /lib/libtirpc.so.3.0.0 /usr/lib/libtirpc.so

 From my point of view are this 2 commands  completely unnecessary, 
because /usr is not on a separate partition. When /lib is available 
/usr is also available.
So I would suggest removing this 2 commands and  leave the libs where 
they are installed.

Otherwise, the patch looks fine.


> 
>  	@rm -rf $(DIR_APP)
>  	@$(POSTBUILD)
> --
> 1.9.1

regards Jonatan
  
Marcel Lorenz July 8, 2016, 5:02 a.m. UTC | #2
Hi Jonatan,

thx for support me... :)

i make my patches, if it working on IPFire, identical to Linux from 
Scratch.
For this lib: 
http://www.linuxfromscratch.org/blfs/view/svn/basicnet/libtirpc.html

if their other notions have, please tell me share this with.
So I can create the patch as desired. For me it is important that it 
just works ...

(google translator)

if you wish, i make it new without --prefix=/usr and mv -v 
/usr/lib/libtirpc.so

regards Marcel

Am 2016-07-05 11:26, schrieb Jonatan Schlag:
> Hi,
> 
> Am So, 26. Jun, 2016 um 10:23 schrieb Marcel Lorenz
> <marcel.lorenz@ipfire.org>:
> 
>> This patch changes the lib from a package to common lsof 4.98 need
>> this lib for working. The lib are moved to /lib. This is the
>> recommendation from:
>> http://www.linuxfromscratch.org/blfs/view/svn/basicnet/libtirpc.html
>> Signed-off-by: Marcel Lorenz <marcel.lorenz@ipfire.org> ---
>> config/rootfiles/{packages => common}/libtirpc | 7 +++----
>> lfs/libtirpc | 21 ++++++++++----------- 2 files changed, 13
>> insertions(+), 15 deletions(-) rename config/rootfiles/{packages =>
>> common}/libtirpc (95%) diff --git
>> a/config/rootfiles/packages/libtirpc
>> b/config/rootfiles/common/libtirpc similarity index 95% rename from
>> config/rootfiles/packages/libtirpc rename to
>> config/rootfiles/common/libtirpc index e197563..02cf846 100644 ---
>> a/config/rootfiles/packages/libtirpc +++
>> b/config/rootfiles/common/libtirpc @@ -1,4 +1,6 @@ etc/netconfig
>> +lib/libtirpc.so.3 +lib/libtirpc.so.3.0.0 #usr/include/tirpc
>> #usr/include/tirpc/netconfig.h #usr/include/tirpc/rpc @@ -33,11
>> +35,8 @@ etc/netconfig #usr/include/tirpc/rpcsvc
>> #usr/include/tirpc/rpcsvc/crypt.h #usr/include/tirpc/rpcsvc/crypt.x
>> -#usr/lib/libtirpc.a #usr/lib/libtirpc.la -#usr/lib/libtirpc.so
>> -usr/lib/libtirpc.so.3 -usr/lib/libtirpc.so.3.0.0
>> +usr/lib/libtirpc.so #usr/lib/pkgconfig/libtirpc.pc
>> #usr/share/man/man3/bindresvport.3t #usr/share/man/man3/des_crypt.3t
>> diff --git a/lfs/libtirpc b/lfs/libtirpc index 382d7e5..65466d0
>> 100644 --- a/lfs/libtirpc +++ b/lfs/libtirpc @@ -1,7 +1,7 @@
>> 
> ###############################################################################
>> # # # IPFire.org - A linux based firewall # -# Copyright (C) 2016
>> IPFire Team <info@ipfire.org> # +# Copyright (C) 2016 IPFire Team
>> <info@ipfire.org> # # # # This program is free software: you can
>> redistribute it and/or modify # # it under the terms of the GNU
>> General Public License as published by # @@ -31,10 +31,6 @@ DL_FILE
>> = $(THISAPP).tar.bz2 DL_FROM = $(URL_IPFIRE) DIR_APP =
>> $(DIR_SRC)/$(THISAPP) TARGET = $(DIR_INFO)/$(THISAPP) -PROG =
>> libtirpc -PAK_VER = 1 - -DEPS = ""
>> 
> ###############################################################################
>> # Top-level Rules @@ -54,9 +50,6 @@ download :$(patsubst
>> %,$(DIR_DL)/%,$(objects)) md5 : $(subst %,%_MD5,$(objects)) -dist: -
>> @$(PAK) -
>> 
> ###############################################################################
>> # Downloading, checking, md5sum
>> 
> ###############################################################################
>> @@ -76,9 +69,15 @@ $(subst %,%_MD5,$(objects)) : $(TARGET) :
>> $(patsubst %,$(DIR_DL)/%,$(objects)) @$(PREBUILD) - @rm -rf
>> $(DIR_APP) && cd $(DIR_SRC) && tar jxf $(DIR_DL)/$(DL_FILE) - cd
>> $(DIR_APP) && ./configure --prefix=/usr --sysconfdir=/etc
>> --disable-gssapi --disable-ipv6 - cd $(DIR_APP) && make
>> $(MAKETUNING) $(EXTRA_MAKE) + @rm -rf $(DIR_APP) && cd $(DIR_SRC) &&
>> tar axf $(DIR_DL)/$(DL_FILE) + cd $(DIR_APP) && ./configure
>> --prefix=/usr \ + --sysconfdir=/etc \ + --disable-static \ +
>> --disable-gssapi \ + --disable-ipv6 + cd $(DIR_APP) && make
>> $(MAKETUNING) cd $(DIR_APP) && make install + mv -v
>> /usr/lib/libtirpc.so.* /lib + ln -sfv /lib/libtirpc.so.3.0.0
>> /usr/lib/libtirpc.so
> 
> From my point of view are this 2 commands  completely unnecessary,
> because /usr is not on a separate partition. When /lib is available
> /usr is also available.
> So I would suggest removing this 2 commands and  leave the libs where
> they are installed.
> 
> Otherwise, the patch looks fine.
> 
>> @rm -rf $(DIR_APP) @$(POSTBUILD)
>> -- 1.9.1
> 
> regards Jonatan
  
Jonatan Schlag July 8, 2016, 5:27 a.m. UTC | #3
Hi Marcel

Marcel Lorenz – Do, 7. Juli 2016 21:02
> Hi Jonatan,
> 
> thx for support me... :)
> 
When I can help I am happy to do so :-)

> i make my patches, if it working on IPFire, identical to Linux from 
> Scratch.
> For this lib: 
> www.linuxfromscratch.org/blfs/view/svn/basicnet/libtirpc.html

This is definitely not the worst source, but there are some differences which make some things not useful on IPFire.

> 
> if their other notions have, please tell me share this with.
> So I can create the patch as desired. For me it is important that it 
> just works ...
> 
It should work definitely :-)  but the advice 

"mv -v /usr/lib/libtirpc.so.* ...: Move shared libraries into /lib so they are available before /usr is mounted."
is not useful for IPFire on IPFire because /usr is not on a separated partition. There are Distribution where /usr is located on a seperated partition. On this Distribution it is useful to move the libs to /lib because they are earlier available as when they are located on the separated partition /usr.

So on IPfire you can ignore this advice.

> (google translator)
> 
> if you wish, i make it new without --prefix=/usr and mv -v 
> /usr/lib/libtirpc.so
> 

Why want you to remove --prefix=/usr ?
We should use --prefix=/usr everywhere else things goes into /usr/local which is bad.

Just remove 
mv -v /usr/lib/libtirpc.so.* /lib
ln -sfv /lib/libtirpc.so.3.0.0 /usr/lib/libtirpc.so

and the patch should fine with some other adjustment

-	@rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar jxf $(DIR_DL)/$(DL_FILE)
Why did you change tar jxf to tar axf ? If there is no reason do do this, do not change this.
-	cd $(DIR_APP) && ./configure --prefix=/usr --sysconfdir=/etc --disable-gssapi --disable-ipv6
-	cd $(DIR_APP) && make $(MAKETUNING) $(EXTRA_MAKE)
Same as 2 lines up  If there is no reason do do this, do not change this.
+	@rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE)
+	cd $(DIR_APP) && ./configure --prefix=/usr \
+			--sysconfdir=/etc \
+			--disable-static \
+			--disable-gssapi \
+			--disable-ipv6
+	cd $(DIR_APP) && make $(MAKETUNING)

And please remove libtirpc as a dependency from rpcbind and bump the package version. Elsewise we run into dependency issues

Regards Jonatan