Created
February 9, 2015 10:26
-
-
Save bitonic/f0daeb4fef219080a6d2 to your computer and use it in GitHub Desktop.
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
# Makefile tweaked for Ubuntu 14.04, install gnustep and gnustep-devel first. | |
HC = ghc | |
LIBDIR = $(shell $(HC) --print-libdir) | |
CFLAGS = -fobjc-arc -I$(LIBDIR)/include -I$(LIBDIR)/../../includes | |
HCFLAGS = | |
LDFLAGS = -package template-haskell -package language-c-quote -package language-c-inline -L/usr/lib/GNUstep/System/Library/Libraries/ -lgnustep-base -lobjc | |
OBJS = Main.o Main_objc.o | |
default: Minimal | |
%.o: %.hs | |
$(HC) -c $< $(HCFLAGS) | |
Main.o: | |
Main_objc.m: Main.o | |
Main_objc.o: Main_objc.m | |
gcc -c -I$(LIBDIR)/include -I/usr/include/GNUstep -fconstant-string-class=NSConstantString -o Main_objc.o Main_objc.m | |
Minimal: $(OBJS) | |
$(HC) -o $@ $^ $(LDFLAGS) | |
.PHONY: clean | |
clean: | |
rm -f *.o *.hi Main_objc.[hmo] Minimal |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment