[v4,1/8] make.sh: Remove crda and remaining python2 modules

Message ID 20210805210152.3467498-1-adolf.belka@ipfire.org
State Accepted
Headers show
Series [v4,1/8] make.sh: Remove crda and remaining python2 modules | expand

Commit Message

Adolf Belka Aug. 5, 2021, 9:01 p.m. UTC
- crda only works with python2 version of m2crypto
   python-m2crypto requires python-setuptools and python-typing
- With Linux kernel 4.15 and later the country code status check that crda did is built
   into the kernel.
- So from kernel 4.15, crda can be removed, which allows removal of m2crypto, setuptools
   and typing.
- python-typing is built into python3 so no additional python3 module required.
- python3 version of python-setuptools has already been installed.
- python3 version of python-m2crypto is not required. python-m2crypto is only used for the
   build of crda.
- ipaddr can be removed as the function of this python2 module is built into python3 with
   ipaddress.py
- removal of crda tested with 5.10.45 kernel and the setting of a country code was
   recognised. If this test carried out with crda removed and 4.14.232 kernel then country
   code stays defined as the global code "00".
- wlanap.cgi uses regdbdump from crda to create a text based list of the
   wireless settings by country database. With the removal of crda a modification is
   required to wireless-reg to copy the db.txt file to a specific location that wlan.cgi
   can then access. db.txt is the text file version of the wireless settings by country
   database.
- This series version copies the db.txt file and renames it regulatorydb.txt and places it in
   /lib/firmware/
- This series version also corrects the loading command from regulatorydb.txt into the
   @countrylist_cmd variable

Signed-off-by: Adolf Belka <adolf.belka@ipfire.org>
---
 make.sh | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

Comments

Arne Fitzenreiter Sept. 6, 2021, 10:47 a.m. UTC | #1
Sorry for late review but this patch alter the IPFire version back to 
2.25.
Should i fix this at merge or want you send a new version ?

Arne


Am 2021-08-05 23:01, schrieb Adolf Belka:
> - crda only works with python2 version of m2crypto
>    python-m2crypto requires python-setuptools and python-typing
> - With Linux kernel 4.15 and later the country code status check that
> crda did is built
>    into the kernel.
> - So from kernel 4.15, crda can be removed, which allows removal of
> m2crypto, setuptools
>    and typing.
> - python-typing is built into python3 so no additional python3 module 
> required.
> - python3 version of python-setuptools has already been installed.
> - python3 version of python-m2crypto is not required. python-m2crypto
> is only used for the
>    build of crda.
> - ipaddr can be removed as the function of this python2 module is
> built into python3 with
>    ipaddress.py
> - removal of crda tested with 5.10.45 kernel and the setting of a
> country code was
>    recognised. If this test carried out with crda removed and 4.14.232
> kernel then country
>    code stays defined as the global code "00".
> - wlanap.cgi uses regdbdump from crda to create a text based list of 
> the
>    wireless settings by country database. With the removal of crda a
> modification is
>    required to wireless-reg to copy the db.txt file to a specific
> location that wlan.cgi
>    can then access. db.txt is the text file version of the wireless
> settings by country
>    database.
> - This series version copies the db.txt file and renames it
> regulatorydb.txt and places it in
>    /lib/firmware/
> - This series version also corrects the loading command from
> regulatorydb.txt into the
>    @countrylist_cmd variable
> 
> Signed-off-by: Adolf Belka <adolf.belka@ipfire.org>
> ---
>  make.sh | 7 +------
>  1 file changed, 1 insertion(+), 6 deletions(-)
> 
> diff --git a/make.sh b/make.sh
> index d78fb2ff0..57b83e432 100755
> --- a/make.sh
> +++ b/make.sh
> @@ -25,7 +25,7 @@
>  NAME="IPFire"							# Software name
>  SNAME="ipfire"							# Short name
>  # If you update the version don't forget to update backupiso and add
> it to core update
> -VERSION="2.27"							# Version number
> +VERSION="2.25"							# Version number
>  CORE="159"							# Core Level (Filename)
>  SLOGAN="www.ipfire.org"						# Software slogan
>  CONFIG_ROOT=/var/ipfire						# Configuration rootdir
> @@ -1296,7 +1296,6 @@ buildipfire() {
>    lfsmake2 whatmask
>    lfsmake2 libtirpc
>    lfsmake2 conntrack-tools
> -  lfsmake2 ipaddr
>    lfsmake2 iputils
>    lfsmake2 l7-protocols
>    lfsmake2 hwdata
> @@ -1333,7 +1332,6 @@ buildipfire() {
>    lfsmake2 XML-Parser
>    lfsmake2 Crypt-PasswdMD5
>    lfsmake2 Net-Telnet
> -  lfsmake2 python-setuptools
>    lfsmake2 python3-setuptools
>    lfsmake2 python3-inotify
>    lfsmake2 python3-docutils
> @@ -1517,10 +1515,7 @@ buildipfire() {
>    lfsmake2 swig
>    lfsmake2 u-boot
>    lfsmake2 u-boot-friendlyarm
> -  lfsmake2 python-typing
> -  lfsmake2 python-m2crypto
>    lfsmake2 wireless-regdb
> -  lfsmake2 crda
>    lfsmake2 libsolv
>    lfsmake2 ddns
>    lfsmake2 python3-setuptools-scm
Michael Tremer Sept. 6, 2021, 10:48 a.m. UTC | #2
Hi Arne,

You can just merge this, then edit make.sh and change the commit using “git commit —-amend”.

That is probably the easiest.

-Michael

> On 6 Sep 2021, at 11:47, Arne Fitzenreiter <arne_f@ipfire.org> wrote:
> 
> Sorry for late review but this patch alter the IPFire version back to 2.25.
> Should i fix this at merge or want you send a new version ?
> 
> Arne
> 
> 
> Am 2021-08-05 23:01, schrieb Adolf Belka:
>> - crda only works with python2 version of m2crypto
>>   python-m2crypto requires python-setuptools and python-typing
>> - With Linux kernel 4.15 and later the country code status check that
>> crda did is built
>>   into the kernel.
>> - So from kernel 4.15, crda can be removed, which allows removal of
>> m2crypto, setuptools
>>   and typing.
>> - python-typing is built into python3 so no additional python3 module required.
>> - python3 version of python-setuptools has already been installed.
>> - python3 version of python-m2crypto is not required. python-m2crypto
>> is only used for the
>>   build of crda.
>> - ipaddr can be removed as the function of this python2 module is
>> built into python3 with
>>   ipaddress.py
>> - removal of crda tested with 5.10.45 kernel and the setting of a
>> country code was
>>   recognised. If this test carried out with crda removed and 4.14.232
>> kernel then country
>>   code stays defined as the global code "00".
>> - wlanap.cgi uses regdbdump from crda to create a text based list of the
>>   wireless settings by country database. With the removal of crda a
>> modification is
>>   required to wireless-reg to copy the db.txt file to a specific
>> location that wlan.cgi
>>   can then access. db.txt is the text file version of the wireless
>> settings by country
>>   database.
>> - This series version copies the db.txt file and renames it
>> regulatorydb.txt and places it in
>>   /lib/firmware/
>> - This series version also corrects the loading command from
>> regulatorydb.txt into the
>>   @countrylist_cmd variable
>> Signed-off-by: Adolf Belka <adolf.belka@ipfire.org>
>> ---
>> make.sh | 7 +------
>> 1 file changed, 1 insertion(+), 6 deletions(-)
>> diff --git a/make.sh b/make.sh
>> index d78fb2ff0..57b83e432 100755
>> --- a/make.sh
>> +++ b/make.sh
>> @@ -25,7 +25,7 @@
>> NAME="IPFire"							# Software name
>> SNAME="ipfire"							# Short name
>> # If you update the version don't forget to update backupiso and add
>> it to core update
>> -VERSION="2.27"							# Version number
>> +VERSION="2.25"							# Version number
>> CORE="159"							# Core Level (Filename)
>> SLOGAN="www.ipfire.org"						# Software slogan
>> CONFIG_ROOT=/var/ipfire						# Configuration rootdir
>> @@ -1296,7 +1296,6 @@ buildipfire() {
>>   lfsmake2 whatmask
>>   lfsmake2 libtirpc
>>   lfsmake2 conntrack-tools
>> -  lfsmake2 ipaddr
>>   lfsmake2 iputils
>>   lfsmake2 l7-protocols
>>   lfsmake2 hwdata
>> @@ -1333,7 +1332,6 @@ buildipfire() {
>>   lfsmake2 XML-Parser
>>   lfsmake2 Crypt-PasswdMD5
>>   lfsmake2 Net-Telnet
>> -  lfsmake2 python-setuptools
>>   lfsmake2 python3-setuptools
>>   lfsmake2 python3-inotify
>>   lfsmake2 python3-docutils
>> @@ -1517,10 +1515,7 @@ buildipfire() {
>>   lfsmake2 swig
>>   lfsmake2 u-boot
>>   lfsmake2 u-boot-friendlyarm
>> -  lfsmake2 python-typing
>> -  lfsmake2 python-m2crypto
>>   lfsmake2 wireless-regdb
>> -  lfsmake2 crda
>>   lfsmake2 libsolv
>>   lfsmake2 ddns
>>   lfsmake2 python3-setuptools-scm

Patch

diff --git a/make.sh b/make.sh
index d78fb2ff0..57b83e432 100755
--- a/make.sh
+++ b/make.sh
@@ -25,7 +25,7 @@ 
 NAME="IPFire"							# Software name
 SNAME="ipfire"							# Short name
 # If you update the version don't forget to update backupiso and add it to core update
-VERSION="2.27"							# Version number
+VERSION="2.25"							# Version number
 CORE="159"							# Core Level (Filename)
 SLOGAN="www.ipfire.org"						# Software slogan
 CONFIG_ROOT=/var/ipfire						# Configuration rootdir
@@ -1296,7 +1296,6 @@  buildipfire() {
   lfsmake2 whatmask
   lfsmake2 libtirpc
   lfsmake2 conntrack-tools
-  lfsmake2 ipaddr
   lfsmake2 iputils
   lfsmake2 l7-protocols
   lfsmake2 hwdata
@@ -1333,7 +1332,6 @@  buildipfire() {
   lfsmake2 XML-Parser
   lfsmake2 Crypt-PasswdMD5
   lfsmake2 Net-Telnet
-  lfsmake2 python-setuptools
   lfsmake2 python3-setuptools
   lfsmake2 python3-inotify
   lfsmake2 python3-docutils
@@ -1517,10 +1515,7 @@  buildipfire() {
   lfsmake2 swig
   lfsmake2 u-boot
   lfsmake2 u-boot-friendlyarm
-  lfsmake2 python-typing
-  lfsmake2 python-m2crypto
   lfsmake2 wireless-regdb
-  lfsmake2 crda
   lfsmake2 libsolv
   lfsmake2 ddns
   lfsmake2 python3-setuptools-scm