#3 Make it build using Python3 instead of Python2
Closed 3 years ago by mfabian. Opened 3 years ago by mfabian.
rpms/ mfabian/malaga-suomi-voikko main  into  main

@@ -0,0 +1,19 @@ 

+ --- suomi-malaga-1.19/voikko/generate_lex.py.~1~	2015-10-03 16:53:40.000000000 +0200

+ +++ suomi-malaga-1.19/voikko/generate_lex.py	2018-07-03 08:37:12.702612632 +0200

+ @@ -24,7 +24,6 @@

+  import voikkoutils

+  import xml.dom.minidom

+  import codecs

+ -from string import rfind

+  

+  flag_attributes = voikkoutils.readFlagAttributes(generate_lex_common.VOCABULARY_DATA + u"/flags.txt")

+  

+ @@ -218,7 +217,7 @@

+  	# then all multi part forms must end with a part contained in the single part set.

+  	if singlePartForms:

+  		for multiPartForm in multiPartForms:

+ -			lastPart = multiPartForm[max(rfind(multiPartForm, u"="), rfind(multiPartForm, u"|"), rfind(multiPartForm, u"-")) + 1:]

+ +			lastPart = multiPartForm[max(multiPartForm.rfind(u"="), multiPartForm.rfind(u"|"), multiPartForm.rfind(u"-")) + 1:]

+  			if lastPart not in singlePartForms:

+  				sys.stderr.write(u"ERROR: suspicious alternative spelling: %s\n" % multiPartForm)

+  				sys.exit(1)

file modified
+9 -4
@@ -1,6 +1,6 @@ 

  Name:           malaga-suomi-voikko

  Version:        1.19

- Release:        13%{?dist}

+ Release:        14%{?dist}

  Summary:        A description of Finnish morphology written in Malaga (Voikko edition)

  

  License:        GPLv2+
@@ -9,9 +9,11 @@ 

  Source0:        http://www.puimula.org/voikko-sources/suomi-malaga/suomi-malaga-%{version}.tar.gz

  # The usual format of testing release source URLs

  #Source0:        http://www.puimula.org/htp/testing/suomi-malaga-%{version}rc3.tar.gz

+ Patch0:         make-it-work-with-python3.patch

  

  BuildRequires: make

- BuildRequires:  malaga >= 7.8 python2

+ BuildRequires:  malaga >= 7.8

+ BuildRequires:  python3-devel

  

  # debuginfo would be empty

  %define debug_package %{nil}
@@ -23,12 +25,12 @@ 

  

  %prep

  %setup -q -n suomi-malaga-%{version}

+ %patch0 -p1 -b .make-it-work-with-python3

  

  

  %build

  # configure removed, not needed in this package

- make %{?_smp_mflags} voikko PYTHON="python2"

- 

+ make %{?_smp_mflags} voikko PYTHON=%{__python3}

  

  %install

  rm -rf $RPM_BUILD_ROOT
@@ -44,6 +46,9 @@ 

  

  

  %changelog

+ * Tue Feb 09 2021 Mike FABIAN <mfabian@redhat.com> - 1.19-14

+ - Make it build using Python3 instead of Python2

+ 

  * Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.19-13

  - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild

  

no initial comment

rebased onto a482a6e

3 years ago

pushed to main and rawhide.

Pull-Request has been closed by mfabian

3 years ago