-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
2,706 additions
and
413 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
# Frequently Asked Questions | ||
|
||
## Surf is starting up slowly. What might happen? | ||
## Surf is starting up slowly. What might be causing this? | ||
|
||
The first suspect for such a behaviour is the plugin handling. Run surf | ||
on the commandline and see if there are errors because of »nspluginwrap‐ | ||
per« or failed RPCs to them. If that is true, go to ~/.mozilla/plugins | ||
and try removing stale links to plugins not on your system anymore. This | ||
The first suspect for such behaviour is the plugin handling. Run surf on | ||
the commandline and see if there are errors because of “nspluginwrapper” | ||
or failed RPCs to them. If that is true, go to ~/.mozilla/plugins and | ||
try removing stale links to plugins not on your system anymore. This | ||
will stop surf from trying to load them. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,61 +1,77 @@ | ||
# surf - simple browser | ||
# See LICENSE file for copyright and license details. | ||
.POSIX: | ||
|
||
include config.mk | ||
|
||
SRC = surf.c | ||
OBJ = ${SRC:.c=.o} | ||
CSRC = common.c | ||
WEBEXTSRC = libsurf-webext.c | ||
OBJ = $(SRC:.c=.o) | ||
COBJ = $(CSRC:.c=.o) | ||
WEBEXTOBJ = $(WEBEXTSRC:.c=.o) | ||
|
||
all: options surf | ||
all: options libsurf-webext.so surf | ||
|
||
options: | ||
@echo surf build options: | ||
@echo "CFLAGS = ${CFLAGS}" | ||
@echo "LDFLAGS = ${LDFLAGS}" | ||
@echo "CC = ${CC}" | ||
@echo "CC = $(CC)" | ||
@echo "CFLAGS = $(SURFCFLAGS) $(CFLAGS)" | ||
@echo "WEBEXTCFLAGS = $(WEBEXTCFLAGS) $(CFLAGS)" | ||
@echo "LDFLAGS = $(LDFLAGS)" | ||
|
||
.c.o: | ||
@echo CC $< | ||
@${CC} -c ${CFLAGS} $< | ||
|
||
${OBJ}: config.h config.mk | ||
$(CC) $(SURFCFLAGS) $(CFLAGS) -c $< | ||
|
||
config.h: | ||
@echo creating $@ from config.def.h | ||
@cp config.def.h $@ | ||
cp config.def.h $@ | ||
|
||
$(OBJ): config.h common.h config.mk | ||
$(COBJ): config.h common.h config.mk | ||
$(WEBEXTOBJ): config.h common.h config.mk | ||
|
||
$(WEBEXTOBJ): $(WEBEXTSRC) | ||
$(CC) $(WEBEXTCFLAGS) $(CFLAGS) -c $(WEBEXTSRC) | ||
|
||
surf: ${OBJ} | ||
@echo CC -o $@ | ||
@${CC} -o $@ surf.o ${LDFLAGS} | ||
libsurf-webext.so: $(WEBEXTOBJ) $(COBJ) | ||
$(CC) -shared -Wl,-soname,$@ $(LDFLAGS) -o $@ \ | ||
$(WEBEXTOBJ) $(COBJ) $(WEBEXTLIBS) | ||
|
||
surf: $(OBJ) $(COBJ) | ||
$(CC) $(SURFLDFLAGS) $(LDFLAGS) -o $@ $(OBJ) $(COBJ) $(LIBS) | ||
|
||
clean: | ||
@echo cleaning | ||
@rm -f surf ${OBJ} surf-${VERSION}.tar.gz | ||
|
||
dist: clean | ||
@echo creating dist tarball | ||
@mkdir -p surf-${VERSION} | ||
@cp -R LICENSE Makefile config.mk config.def.h README \ | ||
surf-open.sh arg.h TODO.md surf.png \ | ||
surf.1 ${SRC} surf-${VERSION} | ||
@tar -cf surf-${VERSION}.tar surf-${VERSION} | ||
@gzip surf-${VERSION}.tar | ||
@rm -rf surf-${VERSION} | ||
rm -f surf $(OBJ) $(COBJ) | ||
rm -f libsurf-webext.so $(WEBEXTOBJ) | ||
|
||
distclean: clean | ||
rm -f config.h surf-$(VERSION).tar.gz | ||
|
||
dist: distclean | ||
mkdir -p surf-$(VERSION) | ||
cp -R LICENSE Makefile config.mk config.def.h README \ | ||
surf-open.sh arg.h TODO.md surf.png \ | ||
surf.1 $(SRC) $(WEBEXTSRC) surf-$(VERSION) | ||
tar -cf surf-$(VERSION).tar surf-$(VERSION) | ||
gzip surf-$(VERSION).tar | ||
rm -rf surf-$(VERSION) | ||
|
||
install: all | ||
@echo installing executable file to ${DESTDIR}${PREFIX}/bin | ||
@mkdir -p ${DESTDIR}${PREFIX}/bin | ||
@cp -f surf ${DESTDIR}${PREFIX}/bin | ||
@chmod 755 ${DESTDIR}${PREFIX}/bin/surf | ||
@echo installing manual page to ${DESTDIR}${MANPREFIX}/man1 | ||
@mkdir -p ${DESTDIR}${MANPREFIX}/man1 | ||
@sed "s/VERSION/${VERSION}/g" < surf.1 > ${DESTDIR}${MANPREFIX}/man1/surf.1 | ||
@chmod 644 ${DESTDIR}${MANPREFIX}/man1/surf.1 | ||
mkdir -p $(DESTDIR)$(PREFIX)/bin | ||
cp -f surf $(DESTDIR)$(PREFIX)/bin | ||
chmod 755 $(DESTDIR)$(PREFIX)/bin/surf | ||
mkdir -p $(DESTDIR)$(LIBDIR) | ||
cp -f libsurf-webext.so $(DESTDIR)$(LIBDIR) | ||
chmod 644 $(DESTDIR)$(LIBDIR)/libsurf-webext.so | ||
mkdir -p $(DESTDIR)$(MANPREFIX)/man1 | ||
sed "s/VERSION/$(VERSION)/g" < surf.1 > $(DESTDIR)$(MANPREFIX)/man1/surf.1 | ||
chmod 644 $(DESTDIR)$(MANPREFIX)/man1/surf.1 | ||
|
||
uninstall: | ||
@echo removing executable file from ${DESTDIR}${PREFIX}/bin | ||
@rm -f ${DESTDIR}${PREFIX}/bin/surf | ||
@echo removing manual page from ${DESTDIR}${MANPREFIX}/man1 | ||
@rm -f ${DESTDIR}${MANPREFIX}/man1/surf.1 | ||
rm -f $(DESTDIR)$(PREFIX)/bin/surf | ||
rm -f $(DESTDIR)$(MANPREFIX)/man1/surf.1 | ||
rm -f $(DESTDIR)$(LIBDIR)/libsurf-webext.so | ||
- rmdir $(DESTDIR)$(LIBDIR) | ||
|
||
.PHONY: all options clean dist install uninstall | ||
.SUFFIXES: .so .o .c | ||
.PHONY: all options clean-dist clean dist install uninstall |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#include <stdarg.h> | ||
#include <stdio.h> | ||
#include <stdlib.h> | ||
|
||
void | ||
die(const char *errstr, ...) | ||
{ | ||
va_list ap; | ||
|
||
va_start(ap, errstr); | ||
vfprintf(stderr, errstr, ap); | ||
va_end(ap); | ||
exit(1); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
#define MSGBUFSZ 8 | ||
|
||
void die(char *, ...); |
Oops, something went wrong.