python-dmidecode/python-dmidecode-use_python3.patch
DistroBaker a9fcfe5214 Merged update from upstream sources
This is an automated DistroBaker update from upstream sources.
If you do not know what this is about or would like to opt out,
contact the OSCI team.

Source: https://src.fedoraproject.org/rpms/python-dmidecode.git#d826fb9119f5a6d8d7cac98111aa465a313e22ef
2020-11-26 17:41:55 +00:00

32 lines
1.0 KiB
Diff

--- a/Makefile.orig 2020-11-26 17:05:32.097857000 +0100
+++ b/Makefile 2020-11-26 17:09:31.660779877 +0100
@@ -38,8 +38,8 @@
#. $AutoHeaderSerial::20100225 $
#. ******* AUTOHEADER END v1.2 *******
-PY_BIN := python2
-VERSION := $(shell cd src;$(PY_BIN) -c "from setup_common import *; print(get_version());")
+PY_BIN := $(PYTHON_BIN)
+VERSION := $(PYTHON_VERSION)
PACKAGE := python-dmidecode
PY_VER := $(shell $(PY_BIN) -c 'import sys; print("%d.%d"%sys.version_info[0:2])')
PY_MV := $(shell echo $(PY_VER) | cut -b 1)
@@ -65,7 +65,7 @@
$(PY) src/setup.py build
dmidump : src/util.o src/efi.o src/dmilog.o
- $(CC) -o $@ src/dmidump.c $^ -g -Wall -D_DMIDUMP_MAIN_
+ $(CC) -o $@ src/dmidump.c $^ $(CFLAGS) -D_DMIDUMP_MAIN_
install:
$(PY) src/setup.py install
--- a/unit-tests/Makefile.orig 2015-06-08 17:19:45.000000000 +0200
+++ b/unit-tests/Makefile 2020-11-26 17:12:15.222361106 +0100
@@ -1,5 +1,5 @@
-PY_BIN := python2
+PY_BIN := $(PYTHON_BIN)
test :
$(PY_BIN) unit -vv