core-agent-linux/misc/Makefile
Marek Marczykowski-Górecki 2478cb5c05
Package DNF plugin for both python2 and python3
DNF in Fedora 22 uses python2, but in Fedora 23 - python3. Package both
of them, in separate packages (according to Fedora packaging guidelines)
and depend on the right one depending on target distribution version.

Fixes QubesOS/qubes-issues#1529
2015-12-23 02:04:26 +01:00

32 lines
685 B
Makefile

CC=gcc
CFLAGS=-Wall -Wextra -Werror -g -O3
_XENSTORE_H=$(wildcard /usr/include/xenstore.h)
ifneq "$(_XENSTORE_H)" ""
CFLAGS+= -DUSE_XENSTORE_H
endif
all: xenstore-watch python close-window
xenstore-watch: xenstore-watch.o
$(CC) -o xenstore-watch xenstore-watch.o -lxenstore
close-window: close-window.c
$(CC) -o $@ $< -lX11
python: python2 python3
python2:
rm -rf py2
mkdir -p py2
cp *.py py2/
python2 -m compileall py2
python2 -O -m compileall py2
# Only some scripts does support python3 for now
python3:
rm -rf py3
mkdir -p py3
cp dnf-qubes-hooks.py xdg.py py3/
python3 -m compileall py3
python3 -O -m compileall py3
clean:
rm -f xenstore-watch *.o *~ *.pyc *.pyo