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.

45 lines
1.4 KiB

  1. --- a/GNUmakefile 2002-11-15 19:57:48.000000000 +0100
  2. +++ a/GNUmakefile 2014-10-02 16:03:02.864803002 +0200
  3. @@ -6,7 +6,7 @@
  4. LDCONFIG ?= /sbin/ldconfig
  5. # Some suggestions: (-mcpu= generates i386 compatible code)
  6. -CFLAGS ?= -O2 -fomit-frame-pointer -pipe -mcpu=i686 -w
  7. +CFLAGS ?= -O2 -pipe -Wall -Werror
  8. #CFLAGS = -O2 -fomit-frame-pointer -pipe -march=i586 -Wall -g
  9. #CFLAGS = -O6 -fomit-frame-pointer -pipe -march=i586 -Wall -ansi -pedantic
  10. #CFLAGS = -O6 -fomit-frame-pointer -pipe -march=i686 -Wall -ansi -pedantic
  11. @@ -15,10 +15,9 @@
  12. #CFLAGS = -g -pg -a -pipe -march=i686 -Wall
  13. #LDFLAGS = -s
  14. -prefix ?= /usr/local
  15. +prefix ?= /usr
  16. libdir ?= $(prefix)/lib
  17. includedir ?= $(prefix)/include
  18. -includedir ?= /usr/include
  19. PROGRAMS = avlsort setdiff
  20. LIBRARY = libavl.so.1.5
  21. @@ -34,16 +33,17 @@
  22. $(CC) $(LDFLAGS) $^ -o $@ $(LIBS)
  23. $(LIBRARY): avl.o
  24. - $(CC) -nostdlib -shared -Wl,-soname,libavl.so.1 $^ -o $@ -lc
  25. + $(CC) -shared -Wl,-soname,libavl.so.1 $^ -o $@ -lc
  26. clean:
  27. $(RM) *.o $(PROGRAMS) libavl.*
  28. install: all
  29. $(INSTALL) -d $(DESTDIR)$(libdir)
  30. - $(INSTALL) avl.h $(DESTDIR)$(includedir)
  31. - $(INSTALL) $(LIBRARIES) $(DESTDIR)$(libdir)
  32. - for i in $(LIBRARIES); do\
  33. + $(INSTALL) -d $(DESTDIR)$(includedir)
  34. + $(INSTALL) -m 644 avl.h $(DESTDIR)$(includedir)
  35. + $(INSTALL) -m 644 $(LIBRARY) $(DESTDIR)$(libdir)
  36. + for i in $(LIBRARY); do\
  37. $(LN) -sf $$i $(DESTDIR)$(libdir)/$${i%.*};\
  38. $(LN) -sf $${i%.*} $(DESTDIR)$(libdir)/$${i%.*.*};\
  39. done