archrelease: copy trunk to community-any
[ArchLinux/community.git] / libglkterm / trunk / libglkterm.patch
blobdc00d5776090e3854abbc175637b98ee2d73fe69
1 diff --no-dereference --ignore-all-space --unified --recursive --text glkterm-glkterm-1.0.4-widechar/gtncursesw.c glkterm-glkterm-1.0.4-widechar-new/gtncursesw.c
2 --- glkterm-glkterm-1.0.4-widechar/gtncursesw.c 2012-10-14 21:21:09.000000000 +0400
3 +++ glkterm-glkterm-1.0.4-widechar-new/gtncursesw.c 2021-09-04 13:48:43.952957333 +0300
4 @@ -92,7 +92,7 @@
5 #else /* LOCAL_NCURSESW */
7 #define _XOPEN_SOURCE_EXTENDED /* ncursesw *wch* and *wstr* functions */
8 -#include <ncursesw/ncurses.h>
9 +#include <ncurses.h>
11 int local_get_wch (wint_t *ch)
13 diff --no-dereference --ignore-all-space --unified --recursive --text glkterm-glkterm-1.0.4-widechar/Makefile glkterm-glkterm-1.0.4-widechar-new/Makefile
14 --- glkterm-glkterm-1.0.4-widechar/Makefile 2012-10-14 21:21:09.000000000 +0400
15 +++ glkterm-glkterm-1.0.4-widechar-new/Makefile 2021-09-04 14:24:41.171037436 +0300
16 @@ -13,8 +13,8 @@
17 CC = gcc -ansi
19 # You may need to set directories to pick up the ncursesw library.
20 -#INCLUDEDIRS = -I/usr/5include
21 -#LIBDIRS = -L/usr/5lib
22 +INCLUDEDIRS = -I/usr/include
23 +LIBDIRS = -L/usr/lib
24 LIBS = -lncursesw
26 # Use this LIBS line instead of the above if you do not have ncursesw
27 @@ -22,11 +22,10 @@
28 # probably also have to set LOCAL_NCURSESW in CFLAGS or in gtoption.h.)
29 #LIBS = -lncurses
31 -OPTIONS = -g -Wall
32 +OPTIONS = -g -Wall -fPIC
34 -CFLAGS = $(OPTIONS) $(INCLUDEDIRS)
36 -GLKLIB = libglktermw.a
37 +CFLAGS += $(OPTIONS) $(INCLUDEDIRS)
38 +GLKLIB = libglkterm.so
40 GLKTERM_OBJS = \
41 main.o gtevent.o gtfref.o gtgestal.o gtinput.o \
42 @@ -39,17 +38,16 @@
43 glkterm.h gtoption.h gtw_blnk.h gtw_buf.h \
44 gtw_grid.h gtw_pair.h gi_dispa.h
46 -all: $(GLKLIB) Make.glktermw
47 +all: $(GLKLIB) Make.glkterm
49 cgunicod.o: cgunigen.c
51 $(GLKLIB): $(GLKTERM_OBJS)
52 - ar r $(GLKLIB) $(GLKTERM_OBJS)
53 - ranlib $(GLKLIB)
54 + ${CC} -shared ${LDFLAGS},-soname,${GLKLIB}.1.0.4 -o ${GLKLIB}.1.0.4 $(GLKTERM_OBJS)
56 -Make.glktermw:
57 - echo LINKLIBS = $(LIBDIRS) $(LIBS) > Make.glktermw
58 - echo GLKLIB = -lglktermw >> Make.glktermw
59 +Make.glkterm:
60 + echo LINKLIBS = $(LIBDIRS) $(LIBS) > Make.glkterm
61 + echo GLKLIB = -lglkterm >> Make.glkterm
63 $(GLKTERM_OBJS): glk.h $(GLKTERM_HEADERS)