<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>33211</bug_id>
          
          <creation_ts>2017-03-07 17:51:12 +0300</creation_ts>
          <short_desc>common filenames of .so modules are not recognized (after pip3 install)</short_desc>
          <delta_ts>2020-02-19 19:31:57 +0300</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>3</classification_id>
          <classification>Distributions</classification>
          <product>Branch p8</product>
          <component>python3</component>
          <version>не указана</version>
          <rep_platform>all</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P3</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          <dependson>33208</dependson>
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Ivan Zakharyaschev">imz</reporter>
          <assigned_to name="Andrey Cherepanov">cas</assigned_to>
          <cc>george</cc>
    
    <cc>glebfm</cc>
    
    <cc>grenka</cc>
    
    <cc>imz</cc>
    
    <cc>vitty</cc>
    
    <cc>vseleznv</cc>
          
          <qa_contact name="qa-p8@altlinux.org">qa-p8</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>162328</commentid>
    <comment_count>0</comment_count>
    <who name="Ivan Zakharyaschev">imz</who>
    <bug_when>2017-03-07 17:51:12 +0300</bug_when>
    <thetext>+++ This bug was initially created as a clone of Bug #33208 +++

python3-3.5.1-alt7

A difference between the commonly used (and recognized) filename for .so Python modules and the idea of ALT&apos;s python3&apos;s idea of it has been discovered (by george@) by trying to use a wheel-Python-package with .so modules:

pip3 install pygame --user
python3 -c &apos;import pygame.base&apos;

It includes a filename of a format like this: 

*.cpython-35m-x86_64-linux-gnu.so

and is not recognized and loaded by ALT&apos;s python3. However, such filenames are generated and used also in Debian and Fedora -- here is an example from Fedora 25 for i386 and x86_64:

$ rpm -qp python3-lxml-3.6.4-1.fc25.i686.rpm -l | fgrep .so
/usr/lib/python3.5/site-packages/lxml/etree.cpython-35m-i386-linux-gnu.so
/usr/lib/python3.5/site-packages/lxml/objectify.cpython-35m-i386-linux-gnu.so
$ 

/usr/lib64/python3.5/site-packages/lxml/etree.cpython-35m-x86_64-linux-gnu.so
/usr/lib64/python3.5/site-packages/lxml/objectify.cpython-35m-x86_64-linux-gnu.so

contrary to filenames generated and recognized in ALT:

$ rpm -q python3-module-lxml -l | fgrep .so
/usr/lib64/python3/site-packages/lxml/etree.cpython-35m.so
/usr/lib64/python3/site-packages/lxml/objectify.cpython-35m.so
$ 

This could be fine, if the binaries were incompatible indeed, but they are loadable and usable after renaming (george@ checked this for pygame).

(Some of ALT&apos;s patches changed this, probably, for no reason... This is a problem for using wheels installed by pip3 without recompilation.)

(In reply to comment #2)
&gt; In Sisyphus, the fix of EXT_SUFFIX Python config parameter (bringing it to the
&gt; more common format) will be convenient to make together with the move to Python
&gt; 3.6. (The binary modules would anyway require a rebuild.)

This is quite clear how to do.

&gt; (As for p8, this should be decided separately. Recognizing the common suffix in
&gt; addition to ours could be a solution with little hassle; otherwise, if we
&gt; change this parameter for the newly built modules, we&apos;d need to track this with
&gt; Provides/Requires to ensure both kinds of modules would be usable.)

This is less clear and requires hacking of a different piece of code (module finding).

Patches (and tasks for p8) are welcome!

See also: https://bugs.python.org/issue16754 which introduced the use of EXT_SUFFIX into the code.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>188051</commentid>
    <comment_count>1</comment_count>
    <who name="Grigory Ustinov">grenka</who>
    <bug_when>2020-02-19 19:31:57 +0300</bug_when>
    <thetext>* Mon Jul 10 2017 Fr. Br. George &lt;george@altlinux.ru&gt; 3.5.1-alt9                 
- Add PLATFORM_TRIPLET suffix for binary module search</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>