#2148 Simplify obtaining of PKGDIR
Merged by tkopecek. Opened by mprivozn.
mprivozn/koji python_fixes  into  master

Download 2148.patch

So far, in all Makefiles we have a complicated way to construct
PKGDIR path which is used to install python modules into.
Firstly, python version is obtained, and then system prefix and
these are then used to construct the PKGDIR path. Well, we can do
better. We can use 'site.getsitepackages()[0]' to obtain exactly
the path we are after.

This also fixes the problem on distributions which have split
/usr/lib and /usr/lib64 directories, because with the way we are
constructing the PKGDIR path we assume that the directories are
the same (or one is a symlink to another). Well, that is not
always the case.

Signed-off-by: Michal Privoznik mprivozn@redhat.com

Issue: #2149

Is there a way to make this py 2.6 compatible? site.getsitepackages is there only from py2.7.

Do we care about python 2.6? Isn't it replaced with 2.7 like everywhere and 2.7 is going away anyway?

Yes, unfortunately we're not leaving py 2.6 yet. In next release (1.22) we're dropping py2 support for everything but builders. I would like to create maintenance branch for RHEL6 in +-1.23 (but we will still need to release patches there).

/We can postpone this one for that release/

See #1942 and #2155

I'm surprised to learn that on RHEL6 somebody would use such new package, but fair enough. Let's postpone this one then.

pretty please pagure-ci rebuild

Metadata Update from @tkopecek:
- Pull-request tagged with: testing-ready

rebased onto 674fff0f7bb446339c93de79bb763ca8560a1013

Commit b75d3cc3 fixes this pull-request

Pull-Request has been merged by tkopecek

Metadata Update from @jcupova:
- Pull-request tagged with: testing-done

Metadata