diff --git a/Makefile b/Makefile
index 1fb42e2..423657a 100644
a
|
b
|
CPPFLAGS += "-DVERSION_MAJOR=${VERSION_MAJOR}" |
18 | 18 | CPPFLAGS += "-DVERSION_MINOR=${VERSION_MINOR}" |
19 | 19 | CPPFLAGS += "-DVERSION_REV=${VERSION_REV}" |
20 | 20 | |
21 | | all: options ${PLUGIN}.so |
| 21 | all: options ${PLUGIN}.dylib |
22 | 22 | |
23 | 23 | zathura-version-check: |
24 | 24 | ifneq ($(ZATHURA_VERSION_CHECK), 0) |
… |
… |
options: |
46 | 46 | ${OBJECTS}: config.mk zathura-version-check |
47 | 47 | ${DOBJECTS}: config.mk zathura-version-check |
48 | 48 | |
49 | | ${PLUGIN}.so: ${OBJECTS} |
| 49 | ${PLUGIN}.dylib: ${OBJECTS} |
50 | 50 | $(ECHO) LD $@ |
51 | | $(QUIET)${CC} -shared ${LDFLAGS} -o $@ $(OBJECTS) ${LIBS} |
| 51 | $(QUIET)${CC} -Wl,-dylib_install_name,${PLUGIN}.dylib -Wl,-bundle_loader,${PREFIX}/bin/zathura -bundle ${LDFLAGS} -o $@ $(OBJECTS) ${LIBS} |
52 | 52 | |
53 | | ${PLUGIN}-debug.so: ${DOBJECTS} |
| 53 | ${PLUGIN}-debug.dylib: ${DOBJECTS} |
54 | 54 | $(ECHO) LD $@ |
55 | 55 | $(QUIET)${CC} -shared ${LDFLAGS} -o $@ $(DOBJECTS) ${LIBS} |
56 | 56 | |
57 | 57 | clean: |
58 | | $(QUIET)rm -rf ${OBJECTS} ${DOBJECTS} $(PLUGIN).so $(PLUGIN)-debug.so \ |
| 58 | $(QUIET)rm -rf ${OBJECTS} ${DOBJECTS} $(PLUGIN).dylib $(PLUGIN)-debug.dylib \ |
59 | 59 | doc .depend ${PROJECT}-${VERSION}.tar.gz zathura-version-check |
60 | 60 | |
61 | | debug: options ${PLUGIN}-debug.so |
| 61 | debug: options ${PLUGIN}-debug.dylib |
62 | 62 | |
63 | 63 | dist: clean |
64 | 64 | $(QUIET)mkdir -p ${PROJECT}-${VERSION} |
… |
… |
doc: clean |
75 | 75 | install: all |
76 | 76 | $(ECHO) installing ${PLUGIN} plugin |
77 | 77 | $(QUIET)mkdir -p ${DESTDIR}${PLUGINDIR} |
78 | | $(QUIET)cp -f ${PLUGIN}.so ${DESTDIR}${PLUGINDIR} |
| 78 | $(QUIET)cp -f ${PLUGIN}.dylib ${DESTDIR}${PLUGINDIR} |
79 | 79 | $(QUIET)mkdir -m 755 -p ${DESTDIR}${DESKTOPPREFIX} |
80 | 80 | $(ECHO) installing desktop file |
81 | 81 | $(QUIET)install -m 644 ${PROJECT}.desktop ${DESTDIR}${DESKTOPPREFIX} |
82 | 82 | |
83 | 83 | uninstall: |
84 | 84 | $(ECHO) uninstalling ${PLUGIN} plugin |
85 | | $(QUIET)rm -f ${DESTDIR}${PLUGINDIR}/${PLUGIN}.so |
86 | | $(QUIET)rmdir --ignore-fail-on-non-empty ${DESTDIR}${PLUGINDIR} 2> /dev/null |
| 85 | $(QUIET)rm -f ${DESTDIR}${PLUGINDIR}/${PLUGIN}.dylib |
| 86 | $(QUIET)rmdir ${DESTDIR}${PLUGINDIR} 2> /dev/null |
87 | 87 | $(ECHO) removing desktop file |
88 | 88 | $(QUIET)rm -f ${DESTDIR}${DESKTOPPREFIX}/${PROJECT}.desktop |
89 | | $(QUIET)rmdir --ignore-fail-on-non-empty ${DESTDIR}${DESKTOPPREFIX} 2> /dev/null |
| 89 | $(QUIET)rmdir ${DESTDIR}${DESKTOPPREFIX} 2> /dev/null |
90 | 90 | |
91 | 91 | -include $(wildcard .depend/*.dep) |
92 | 92 | |