On Fri, 2019-01-25 at 17:55 +0100, Magnus Ihse Bursie wrote: > > > On 2019-01-25 16:27, Severin Gehwolf wrote: > > Hi, > > > > I'm working on an enhancement for jlink. In particular a platform > > specific plugin. I.e. It would only get built on unix/linux > > platforms. > > My trouble is getting some resouce properties set up properly. In > > my > > example there is two versions of plugins.properties: one in > > shared/classes one in unix/classes. These, need to get merged into > > one > > via the MergeProperties build tool class. So far so good. But for > > the > > cases where there is only one resource property it should just get > > copied to support/gensrc and that source root be used for compiling > > those properties into actual ListResourceBundle Java classes. > > > > The copying from the src tree to the gensrc tree doesn't seem to > > work. > > I've tried using $(CP) and SetupCopyFiles to no avail. Would > > anybody > > willing to help? > SetupCopyFile should work, but in this case I think it's simplest to > just use install-file. Like this perhaps: > > ifneq ($$($1_NUM_INPUT_FILES), 1) > $$($1_TARGET): $$($1_INPUT_FILES) > $$(call LogInfo, Merging $$($1_NUM_INPUT_FILES) properties > files into a single properties file for jdk.jlink) > $(TOOL_MERGE_PROPERTIES) \ > $(GENERATED_JLINK_RESOURCES_DIR)/$$($1_PROP).properties > \ > $$($1_INPUT_FILES) > else > $$($1_TARGET): $$($1_INPUT_FILES) > $$(install-file) > endif > > $1 += $$($1_TARGET) > > /Magnus
Thanks, Magnus! Cheers, Severin