CFLAGS =  `pkg-config --cflags --libs gtk+-2.0` 
CC = gcc

all: system-update-applet

system-update-applet:system-update-applet.c common.c window_main.c auto_update_window.c manual_update_window.c patch_update_window.c
	${CC} -g ${CFLAGS} $^ -o $@ 

clean:
	rm -f system-update-applet

install:
	install -d ${DESTDIR}/usr/bin/
	install -m 0755 system-update-applet ${DESTDIR}/usr/bin/
	install -d system-update-base ${DESTDIR}/usr/share/system-update/
	install -m 0755 system-update-base/* ${DESTDIR}/usr/share/system-update/
	install -m 0755 scripts/* ${DESTDIR}/usr/share/system-update/
	install -d ${DESTDIR}/usr/share/applications/
	install -m 0755 system-update-applet.desktop ${DESTDIR}/usr/share/applications/

uninstall:
	rm -f ${DESTDIR}/usr/bin/system-update-applet
	rm -rf ${DESTDIR}/usr/share/system-update/
	rm -f ${DESTDIR}/usr/share/applications/system-update-applet.desktop
