accessible/public/ia2/Makefile.in
author Mike Hommey <mh+mozilla@glandium.org>
Sat, 04 Aug 2012 10:38:41 +0200
changeset 101426 1fc17369c9a6c85dfd5724b9b6ecc073f0b3cc6c
parent 101418 2ef51674316aadfe26a46877b16794f758bf4b6d
child 101442 162130598df094e19b044610902abecd403278d3
permissions -rw-r--r--
Backout changeset 2ef51674316a (bug 774032 bonus) for various Mochitest bustages on a CLOSED TREE

# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

DEPTH     = ../../..
topsrcdir = @top_srcdir@
srcdir    = @srcdir@
VPATH     = @srcdir@

LIBRARY_NAME  = IA2Marshal
MODULE        = accessibility
GRE_MODULE    = 1
DEFFILE       = $(win_srcdir)/IA2Marshal.def

IA2DIR        = $(topsrcdir)/other-licenses/ia2

include $(DEPTH)/config/autoconf.mk

DEFINES       += -DREGISTER_PROXY_DLL

GARBAGE       += $(MIDL_GENERATED_FILES)

FORCE_SHARED_LIB = 1

SRCS_IN_OBJDIR   = 1

MIDL_INTERFACES = \
  Accessible2.idl \
  AccessibleAction.idl \
  AccessibleApplication.idl \
  AccessibleComponent.idl \
  AccessibleEditableText.idl \
  AccessibleHyperlink.idl \
  AccessibleHypertext.idl \
  AccessibleImage.idl \
  AccessibleRelation.idl \
  AccessibleTable.idl \
  AccessibleTable2.idl \
  AccessibleTableCell.idl \
  AccessibleText.idl \
  AccessibleValue.idl \
  $(NULL)

MIDL_ENUMS = \
  AccessibleEventId.idl \
  AccessibleRole.idl \
  AccessibleStates.idl \
  IA2CommonTypes.idl \
  $(NULL)

EXPORTS = \
  $(MIDL_INTERFACES:%.idl=%.h) \
  $(MIDL_INTERFACES:%.idl=%_i.c) \
  $(MIDL_ENUMS:%.idl=%.h) \
  $(NULL)

CSRCS	= \
  dlldata.c \
  $(MIDL_INTERFACES:%.idl=%_p.c) \
  $(MIDL_INTERFACES:%.idl=%_i.c) \
  $(NULL)

MIDL_GENERATED_FILES = \
  dlldata.c \
  $(MIDL_INTERFACES:%.idl=%_p.c) \
  $(MIDL_INTERFACES:%.idl=%_i.c) \
  $(MIDL_INTERFACES:%.idl=%.h) \
  $(MIDL_ENUMS:%.idl=%.h) \
  $(NULL)

EMBED_MANIFEST_AT = 2

include $(topsrcdir)/config/rules.mk

OS_LIBS = \
  kernel32.lib \
  rpcns4.lib \
  rpcrt4.lib \
  ole32.lib \
  oleaut32.lib \
  $(NULL)

# generate list of to-be-generated files that are missing
# but ignore special file dlldata.c
missing:=$(strip $(foreach onefile,$(strip $(subst dlldata.c,,$(MIDL_GENERATED_FILES))),$(if $(wildcard $(onefile)),,$(onefile))))

missing_base:=$(sort $(basename $(subst _p.c,,$(subst _i.c,,$(missing)))))

$(MIDL_GENERATED_FILES) : midl_done

ifneq ("$(missing)","")
midl_done : FORCE
endif

midl_done : $(addprefix $(IA2DIR)/,$(MIDL_INTERFACES) $(MIDL_ENUMS))
	for idl in $(sort $(subst FORCE,,$?) $(addsuffix .idl,$(addprefix $(IA2DIR)/,$(missing_base)))); do \
	  $(MIDL) $(MIDL_FLAGS) -app_config -I $(IA2DIR) -Oicf $$idl; \
	done
	touch $@

# This marshall dll is also registered in the installer
register::
	regsvr32 -s $(DIST)/bin/$(SHARED_LIBRARY)