]> git.armaanb.net Git - asd-repo.git/blob - core/libtermkey/patches/static-no-libtool.patch
248937dbbc0525752b733f39fa6d5cc16f0bb6ed
[asd-repo.git] / core / libtermkey / patches / static-no-libtool.patch
1 diff --git a/Makefile b/Makefile
2 index 199f143..b413b36 100644
3 --- a/Makefile
4 +++ b/Makefile
5 @@ -67,11 +67,14 @@ MAN7DIR=$(MANDIR)/man7
6  all: $(LIBRARY) $(DEMOS)
7  
8  %.lo: %.c termkey.h termkey-internal.h
9 -       $(LIBTOOL) --mode=compile --tag=CC $(CC) $(CFLAGS) -o $@ -c $<
10 +       $(CC) $(CFLAGS) -fPIC -o $@ -c $<
11  
12  $(LIBRARY): $(OBJECTS)
13         $(LIBTOOL) --mode=link --tag=CC $(CC) -rpath $(LIBDIR) -version-info $(VERSION_CURRENT):$(VERSION_REVISION):$(VERSION_AGE) $(LDFLAGS) -o $@ $^
14  
15 +libtermkey.a: $(OBJECTS)
16 +       $(AR) rc $@ $^
17 +
18  demo: $(LIBRARY) demo.lo
19         $(LIBTOOL) --mode=link --tag=CC $(CC) -o $@ $^
20  
21 @@ -106,7 +109,6 @@ clean: clean-test
22  
23  .PHONY: install
24  install: install-inc install-lib install-man
25 -       $(LIBTOOL) --mode=finish $(DESTDIR)$(LIBDIR)
26  
27  install-inc: termkey.h
28         install -d $(DESTDIR)$(INCDIR)
29 @@ -114,9 +116,9 @@ install-inc: termkey.h
30         install -d $(DESTDIR)$(LIBDIR)/pkgconfig
31         LIBDIR=$(LIBDIR) INCDIR=$(INCDIR) VERSION=$(VERSION) sh termkey.pc.sh >$(DESTDIR)$(LIBDIR)/pkgconfig/termkey.pc
32  
33 -install-lib: $(LIBRARY)
34 +install-lib: libtermkey.a
35         install -d $(DESTDIR)$(LIBDIR)
36 -       $(LIBTOOL) --mode=install install libtermkey.la $(DESTDIR)$(LIBDIR)/libtermkey.la
37 +       install libtermkey.a $(DESTDIR)$(LIBDIR)/libtermkey.a
38  
39  install-man:
40         install -d $(DESTDIR)$(MAN3DIR)