blob: de4f4bdfa327bbd96b0c3d0e7a7f7158d31acbe7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
|
# imagefile - tools to convert to imagefile and back
# See LICENSE file for copyright and license details
include config.mk
SRC = png2imagefile.c imagefile2png.c
OBJ = ${SRC:.c=.o}
all: options png2imagefile imagefile2png
options:
@echo imagefile build options:
@echo "CFLAGS = ${CFLAGS}"
@echo "LDFLAGS = ${LDFLAGS}"
@echo "CC = ${CC}"
.c.o:
@echo CC $<
@${CC} -c -o $@ ${CFLAGS} $<
${OBJ}: config.mk
png2imagefile: png2imagefile.o
@echo CC -o $@
@${CC} -o $@ png2imagefile.o ${LDFLAGS}
imagefile2png: imagefile2png.o
@echo CC -o $@
@${CC} -o $@ imagefile2png.o ${LDFLAGS}
clean:
@echo cleaning
@rm -f png2imagefile imagefile2png ${OBJ}
install: all
@echo installing executable files to ${DESTDIR}${PREFIX}/bin
@mkdir -p ${DESTDIR}${PREFIX}/bin
@cp -f png2imagefile imagefile2png ${DESTDIR}${PREFIX}/bin
@chmod 755 ${DESTDIR}${PREFIX}/bin/png2imagefile
@chmod 755 ${DESTDIR}${PREFIX}/bin/imagefile2png
uninstall:
@echo removing executable files from ${DESTDIR}${PREFIX}/bin
@rm -f ${DESTDIR}${PREFIX}/bin/png2imagefile
@rm -f ${DESTDIR}${PREFIX}/bin/imagefile2png
.PHONY: all options clean install uninstall
|