A Simple X Image Viewer
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

34 lines
606 B

  1. all: sxiv
  2. VERSION=git-20110217
  3. CC?=gcc
  4. PREFIX?=/usr/local
  5. CFLAGS+= -Wall -pedantic -DVERSION=\"$(VERSION)\"
  6. LDFLAGS+=
  7. LIBS+= -lX11 -lImlib2
  8. SRCFILES=$(wildcard *.c)
  9. OBJFILES=$(SRCFILES:.c=.o)
  10. sxiv: $(OBJFILES)
  11. $(CC) $(LDFLAGS) -o $@ $^ $(LIBS)
  12. %.o: %.c Makefile config.h
  13. $(CC) $(CFLAGS) -c -o $@ $<
  14. install: all
  15. install -D -m 755 -o root -g root sxiv $(PREFIX)/bin/sxiv
  16. mkdir -p $(PREFIX)/share/man/man1
  17. sed "s/VERSION/$(VERSION)/g" sxiv.1 > $(PREFIX)/share/man/man1/sxiv.1
  18. chmod 644 $(PREFIX)/share/man/man1/sxiv.1
  19. clean:
  20. rm -f sxiv *.o
  21. tags: *.h *.c
  22. ctags $^
  23. cscope: *.h *.c
  24. cscope -b