summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorRobin Watts <Robin.Watts@artifex.com>2011-04-25 13:15:26 +0100
committerRobin Watts <Robin.Watts@artifex.com>2011-04-25 13:15:26 +0100
commitb86564890124c50fb711a0ce8ff42143a36c7a67 (patch)
tree8571786e021d9e6297a7f0b04b6a2b3373ba7a0f /Makefile
parent345a7bb9ee91f047b9c450c7f935df1e5b1fc553 (diff)
downloadmupdf-b86564890124c50fb711a0ce8ff42143a36c7a67.tar.xz
Makefile tweaks for cross compiling, plus example cross compile target.
Add 2 new makefile options to Mupdf. If CROSSCOMPILE is defined, then we avoid performing tasks during the build that require a binary to be built and then executed as part of the build. Currently this is just the cmap and font dumping steps. If NOX11 is defined, then we avoid building the X11 app. Finally, in Makerules, we have a new section to show how to encapsulate the changes for a given cross compile target. If OS is defined to be "beagle-cross" then we build using given compilers/options.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile4
1 files changed, 4 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 38b49c5a..209fce11 100644
--- a/Makefile
+++ b/Makefile
@@ -106,8 +106,10 @@ $(GEN)/font_cjk.h : $(FONT_CJK_SRC)
CMAP_HDR := $(addprefix $(GEN)/, cmap_cns.h cmap_gb.h cmap_japan.h cmap_korea.h)
FONT_HDR := $(GEN)/font_base14.h $(GEN)/font_droid.h $(GEN)/font_cjk.h
+ifeq "$(CROSSCOMPILE)" ""
$(CMAP_HDR) : $(CMAPDUMP) | $(GEN)
$(FONT_HDR) : $(FONTDUMP) | $(GEN)
+endif
$(OUT)/pdf_cmap_table.o : $(CMAP_HDR)
$(OUT)/pdf_fontfile.o : $(FONT_HDR)
@@ -123,8 +125,10 @@ $(XPS_APPS) : $(MUXPS_LIB) $(FITZ_LIB) $(THIRD_LIBS)
MUPDF := $(OUT)/mupdf
$(MUPDF) : $(MUXPS_LIB) $(MUPDF_LIB) $(FITZ_LIB) $(THIRD_LIBS)
+ifeq "$(NOX11)" ""
$(MUPDF) : $(addprefix $(OUT)/, x11_main.o x11_image.o pdfapp.o)
$(LINK_CMD) $(X11_LIBS)
+endif
# --- Install ---