5 $(error You must source "shell-setup" in the shell before running make.)
11 IDL_TYPES := net/mattmccutchen/measurements/XMeasurementsAddIn
15 idlc -C -I$(OOO_BASIS)/sdk/idl -O$(dir $@) $<
17 pkg/$(NAME).uno.rdb: $(patsubst %,urd/%.urd,$(IDL_TYPES))
20 bin-types: pkg/$(NAME).uno.rdb
22 mkdir -p $(addprefix $@/,$(dir $(IDL_TYPES)))
23 # javamaker is temperamental and demands the ./
24 javamaker -BUCR -nD -T$(subst /,.,$(subst $(empty) ,;,$(IDL_TYPES))) -O./$@ $(OOO_BASIS)/ure-link/share/misc/types.rdb $<
28 # The Eclipse Java builder must be run externally to update "$@".
31 # We collect both types and implementation into this jar.
32 # It seems that the manifest has to be first, so handle it specially.
33 pkg/$(NAME).uno.jar: bin-types bin
34 cd bin && fastjar -cMf ../$@ META-INF/MANIFEST.MF
35 cd bin-types && fastjar -uMf ../$@ $(addsuffix .class,$(IDL_TYPES))
36 cd bin && find . -name '*.class' | LC_COLLATE=C sort | fastjar -uMf ../$@ -@
37 .PHONY: pkg/$(NAME).uno.jar
39 PKG_FILES := description.xml extension-description.txt \
40 META-INF/manifest.xml $(NAME).uno.rdb $(NAME).uno.jar
42 $(NAME).oxt: $(addprefix pkg/,$(PKG_FILES))
43 cd pkg && fastjar -cMf ../$@ $(PKG_FILES)
46 # Clean "bin" with the Eclipse Java builder if desired.
47 rm -rf urd pkg/$(NAME).uno.rdb bin-types pkg/$(NAME).uno.jar $(NAME).oxt