--- /dev/null
+flags += -DCY_ATTACH
+code += Handler.o
+inject += Mach/Inject.o
+Mach/Inject.o: Trampoline.t.hpp Baton.hpp
+
+%.t.hpp: %.t.cpp
+ $(target)gcc -c -fno-exceptions -Iinclude -o $*.t.o $< && { file=($$($(target)otool -l $*.t.o | sed -e 'x; /^1/ { x; /^ *filesize / { s/^.* //; p; }; /^ *fileoff / { s/^.* //; p; }; x; }; x; /^ *cmd LC_SEGMENT$$/ { s/.*/1/; x; }; d;')); od -t x1 -j $${file[0]} -N $${file[1]} $*.t.o | sed -e 's/^[^ ]*//' | tr $$'\n' ' ' | sed -e 's/ */ /g;s/^ *//;s/ $$//;s/ /,/g;s/\([^,][^,]\)/0x\1/g' | sed -e 's/^/static const char $*_[] = {/;s/$$/};/' && echo && echo "/*" && $(target)otool -vVt $*.t.o && echo "*/"; } >$@ && rm -f $*.t.o
-# XXX: objective-c exists on non-Darwin
-
dll := dylib
link += -lobjc -framework CoreFoundation
console += -framework Foundation
library += -framework WebKit
library += -liconv
-flags += -DCY_ATTACH
-code += Handler.o
-inject += Mach/Inject.o
-Mach/Inject.o: Trampoline.t.hpp Baton.hpp
-
-%.t.hpp: %.t.cpp
- $(target)gcc -c -fno-exceptions -Iinclude -o $*.t.o $< && { file=($$($(target)otool -l $*.t.o | sed -e 'x; /^1/ { x; /^ *filesize / { s/^.* //; p; }; /^ *fileoff / { s/^.* //; p; }; x; }; x; /^ *cmd LC_SEGMENT$$/ { s/.*/1/; x; }; d;')); od -t x1 -j $${file[0]} -N $${file[1]} $*.t.o | sed -e 's/^[^ ]*//' | tr $$'\n' ' ' | sed -e 's/ */ /g;s/^ *//;s/ $$//;s/ /,/g;s/\([^,][^,]\)/0x\1/g' | sed -e 's/^/static const char $*_[] = {/;s/$$/};/' && echo && echo "/*" && $(target)otool -vVt $*.t.o && echo "*/"; } >$@ && rm -f $*.t.o
-
include Execute.mk
include ObjectiveC.mk
export PATH := /usr/local/bin:/usr/local/GNUstep/System/Tools:$(PATH)
gcc := g++42
flags += -fPIC
-include PkgConfig.mk
+include WebKit.mk
flags += -fPIC
-include PkgConfig.mk
+include WebKit.mk
+++ /dev/null
-ifneq ($(shell pkg-config webkit-1.0 --modversion 2>/dev/null),)
-flags += $(shell pkg-config --cflags webkit-1.0)
-library += $(shell pkg-config --libs webkit-1.0)
-include Execute.mk
-else
-ifneq ($(shell pkg-config WebKitGtk --modversion 2>/dev/null),)
-flags += $(shell pkg-config --cflags WebKitGtk)
-library += $(shell pkg-config --libs WebKitGtk)
-include Execute.mk
-endif
-endif
--- /dev/null
+ifneq ($(shell pkg-config webkit-1.0 --modversion 2>/dev/null),)
+flags += $(shell pkg-config --cflags webkit-1.0)
+library += $(shell pkg-config --libs webkit-1.0)
+include Execute.mk
+else
+ifneq ($(shell pkg-config WebKitGtk --modversion 2>/dev/null),)
+flags += $(shell pkg-config --cflags WebKitGtk)
+library += $(shell pkg-config --libs WebKitGtk)
+include Execute.mk
+endif
+endif
restart ?= $(MAKE)
uname_s ?= $(shell uname -s)
uname_p ?= $(shell uname -p)
+uname_m ?= $(shell uname -m)
-include $(uname_s).mk
-include $(uname_s)-$(uname_p).mk
+-include $(uname_s)-$(uname_m).mk
+
+ifneq ($(shell pkg-config libffi --modversion 2>/dev/null),)
+flags += $(shell pkg-config --cflags libffi)
+endif
ifdef CY_EXECUTE
ifeq ($(filter ObjectiveC,$(filters)),)