Use python2/3 instead of python in Makefile/spec
Fixes: https://pagure.io/koji/issue/1018
This commit is contained in:
parent
c203afe7c2
commit
ccdb8ac34c
8 changed files with 3 additions and 8 deletions
1
Makefile
1
Makefile
|
|
@ -1,6 +1,7 @@
|
|||
NAME=koji
|
||||
SPECFILE = $(firstword $(wildcard *.spec))
|
||||
SUBDIRS = hub builder koji cli util www plugins vm
|
||||
PYTHON=python2
|
||||
|
||||
ifdef DIST
|
||||
DIST_DEFINES := --define "dist $(DIST)"
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
SUBDIRS=koji_cli
|
||||
|
||||
PYTHON=python
|
||||
PACKAGE = $(shell basename `pwd`)
|
||||
PYVER := $(shell $(PYTHON) -c 'import sys; print("%.3s" %(sys.version))')
|
||||
PYSYSDIR := $(shell $(PYTHON) -c 'import sys; print(sys.prefix)')
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
PYFILES = $(wildcard *.py)
|
||||
|
||||
PYTHON=python
|
||||
PACKAGE = $(shell basename `pwd`)
|
||||
PYVER := $(shell $(PYTHON) -c 'import sys; print("%.3s" % (sys.version))')
|
||||
PYSYSDIR := $(shell $(PYTHON) -c 'import sys; print(sys.prefix)')
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
PYTHON=python
|
||||
PACKAGE = $(shell basename `pwd`)
|
||||
PYFILES = $(wildcard *.py)
|
||||
PYVER := $(shell $(PYTHON) -c 'import sys; print("%.3s" %(sys.version))')
|
||||
|
|
|
|||
|
|
@ -268,7 +268,7 @@ koji-web is a web UI to the Koji system.
|
|||
|
||||
%install
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
make DESTDIR=$RPM_BUILD_ROOT %{?install_opt} install
|
||||
make DESTDIR=$RPM_BUILD_ROOT PYTHON=python2 %{?install_opt} install
|
||||
%if 0%{with python3}
|
||||
cd koji
|
||||
make DESTDIR=$RPM_BUILD_ROOT PYTHON=python3 %{?install_opt} install
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
PYTHON=python
|
||||
PACKAGE = $(shell basename `pwd`)
|
||||
ifeq ($(PYTHON), python3)
|
||||
# for python3 we fully support only basic library + CLI
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
PYTHON=python
|
||||
PYVER := $(shell $(PYTHON) -c 'import sys; print("%.3s" %(sys.version))')
|
||||
PYSYSDIR := $(shell $(PYTHON) -c 'import sys; print(sys.prefix)')
|
||||
PYLIBDIR = $(PYSYSDIR)/lib/python$(PYVER)
|
||||
|
|
@ -29,7 +28,7 @@ install:
|
|||
echo "ERROR: A destdir is required"; \
|
||||
exit 1; \
|
||||
fi
|
||||
if [ "$(PYTHON)" == "python" ] ; then \
|
||||
if [ "$(PYTHON)" == "python2" ] ; then \
|
||||
mkdir -p $(DESTDIR)/$(HUBPLUGINDIR); \
|
||||
mkdir -p $(DESTDIR)/$(BUILDERPLUGINDIR); \
|
||||
install -p -m 644 $(HUBFILES) $(DESTDIR)/$(HUBPLUGINDIR); \
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
PYTHON=python
|
||||
PACKAGE = $(shell basename `pwd`)
|
||||
PYFILES = $(wildcard *.py)
|
||||
PYVER := $(shell $(PYTHON) -c 'import sys; print("%.3s" % (sys.version))')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue