parlay

yet another gentoo overlay
git clone https://git.parazyd.org/parlay
Log | Files | Refs | README

surf-2.0-gentoo.patch (2393B)


      1 --- a/config.mk
      2 +++ b/config.mk
      3 @@ -4,28 +4,28 @@
      4  # Customize below to fit your system
      5  
      6  # paths
      7 -PREFIX = /usr/local
      8 +PREFIX = /usr
      9  MANPREFIX = ${PREFIX}/share/man
     10  LIBPREFIX = ${PREFIX}/lib/surf
     11  
     12 -X11INC = /usr/X11R6/include
     13 -X11LIB = /usr/X11R6/lib
     14 +X11INC = $(shell $(PKG_CONFIG) --cflags x11)
     15 +X11LIB = $(shell $(PKG_CONFIG) --libs x11)
     16  
     17 -GTKINC = `pkg-config --cflags gtk+-3.0 webkit2gtk-4.0`
     18 -GTKLIB = `pkg-config --libs gtk+-3.0 webkit2gtk-4.0`
     19 +GTKINC = $(shell $(PKG_CONFIG) --cflags gtk+-3.0 gthread-2.0 webkit2gtk-4.0)
     20 +GTKLIB = $(shell $(PKG_CONFIG) --libs gtk+-3.0 gthread-2.0 webkit2gtk-4.0)
     21  
     22  # includes and libs
     23 -INCS = -I. -I/usr/include -I${X11INC} ${GTKINC}
     24 -LIBS = -L/usr/lib -lc -L${X11LIB} -lX11 ${GTKLIB} -lgthread-2.0
     25 +INCS = -I. -I/usr/include ${X11INC} ${GTKINC}
     26 +LIBS = ${X11LIB} ${GTKLIB}
     27  
     28  # flags
     29  CPPFLAGS = -DVERSION=\"${VERSION}\" -DWEBEXTDIR=\"${LIBPREFIX}\" -D_DEFAULT_SOURCE
     30 -CFLAGS = -std=c99 -pedantic -Wall -Os ${INCS} ${CPPFLAGS}
     31 -LDFLAGS = -s ${LIBS}
     32 +CFLAGS = -std=c99 -pedantic -Wall ${INCS} ${CPPFLAGS}
     33 +LDFLAGS = ${LIBS}
     34  
     35  # Solaris
     36  #CFLAGS = -fast ${INCS} -DVERSION=\"${VERSION}\"
     37  #LDFLAGS = ${LIBS}
     38  
     39  # compiler and linker
     40 -CC = cc
     41 +CC ?= cc
     42 --- a/Makefile
     43 +++ b/Makefile
     44 @@ -15,18 +15,16 @@
     45  	@echo "CC       = ${CC}"
     46  
     47  .c.o:
     48 -	@echo CC $<
     49 -	@${CC} -c ${CFLAGS} $<
     50 +	${CC} -c ${CFLAGS} $<
     51  
     52  ${OBJ}: config.h config.mk
     53  
     54  config.h:
     55  	@echo creating $@ from config.def.h
     56 -	@cp config.def.h $@
     57 +	cp config.def.h $@
     58  
     59  surf: ${OBJ}
     60 -	@echo CC -o $@
     61 -	@${CC} -o $@ surf.o ${LDFLAGS}
     62 +	${CC} -o $@ surf.o ${LDFLAGS}
     63  
     64  clean:
     65  	@echo cleaning
     66 @@ -44,13 +42,13 @@
     67  
     68  install: all
     69  	@echo installing executable file to ${DESTDIR}${PREFIX}/bin
     70 -	@mkdir -p ${DESTDIR}${PREFIX}/bin
     71 -	@cp -f surf ${DESTDIR}${PREFIX}/bin
     72 -	@chmod 755 ${DESTDIR}${PREFIX}/bin/surf
     73 +	mkdir -p ${DESTDIR}${PREFIX}/bin
     74 +	cp -f surf ${DESTDIR}${PREFIX}/bin
     75 +	chmod 755 ${DESTDIR}${PREFIX}/bin/surf
     76  	@echo installing manual page to ${DESTDIR}${MANPREFIX}/man1
     77 -	@mkdir -p ${DESTDIR}${MANPREFIX}/man1
     78 -	@sed "s/VERSION/${VERSION}/g" < surf.1 > ${DESTDIR}${MANPREFIX}/man1/surf.1
     79 -	@chmod 644 ${DESTDIR}${MANPREFIX}/man1/surf.1
     80 +	mkdir -p ${DESTDIR}${MANPREFIX}/man1
     81 +	sed "s/VERSION/${VERSION}/g" < surf.1 > ${DESTDIR}${MANPREFIX}/man1/surf.1
     82 +	chmod 644 ${DESTDIR}${MANPREFIX}/man1/surf.1
     83  
     84  uninstall:
     85  	@echo removing executable file from ${DESTDIR}${PREFIX}/bin