# -*- Makefile -*-
#
# @file  Makefile.BackInput# @brief RTComponent makefile for "BackInput component"
# @date  $Date$
#
# This file is generated by rtc-template with the following argments.
#
#  /usr/bin/rtc-template -bcxx --module-name=BackInput  \
#  --module-type=DataFlowComponent --module-desc=Swtich input component  \
#  --module-version=1.0 --module-vendor=AIST --module-category=example  \
#  --module-comp-type=DataFlowComponent --module-act-type=SPORADIC  \
#  --module-max-inst=10 --outport=outVel:IIS::TimedVelocity  \
#  --inport=inVelJoy:IIS::TimedVelocity  \
#  --inport=inVelAuto:IIS::TimedVelocity --consumer-idl=intellirobot.idl  
#
#
# $Id$
#
CXX      = `rtm-config --cxx`
CXXFLAGS = `rtm-config --cflags` -I.
LDFLAGS  = `rtm-config --libs`
SHFLAGS  = -shared

IDLC     = `rtm-config --idlc`
IDLFLAGS = `rtm-config --idlflags` -I`rtm-config --prefix`/include/rtm/idl
WRAPPER  = rtm-skelwrapper
WRAPPER_FLAGS = --include-dir="" --skel-suffix=Skel --stub-suffix=Stub

SKEL_OBJ =  intellirobotStub.o
STUB_OBJ =  
IMPL_OBJ =  
OBJS     = BackInput.o $(SKEL_OBJ) $(STUB_OBJ) $(IMPL_OBJ)

.SUFFIXES : .so

all: BackInput.so BackInputComp


.cpp.o:
	rm -f $@
	$(CXX) $(CXXFLAGS) -c -o $@ $<

.o.so:
	rm -f $@
	$(CXX) $(SHFLAGS) -o $@ $(OBJS) $(LDFLAGS)

BackInputComp: BackInputComp.o $(OBJS)
	$(CXX) -o $@ $(OBJS) BackInputComp.o $(LDFLAGS) 


clean: clean_objs clean_skelstub
	rm -f *~

clean_objs:
	rm -f $(OBJS) BackInputComp.o BackInput.so BackInputComp

clean_skelstub:
	rm -f *Skel.h *Skel.cpp
	rm -f *Stub.h *Stub.cpp

# add start 2011.01.24 by rtc-center
install:
	cp -p BackInputComp ../../../bin/comp
	cp -p BackInput.so ../../../bin/so
# add end   2011.01.24 by rtc-center

intellirobotStub.cpp : intellirobot.idl
	$(IDLC) $(IDLFLAGS) intellirobot.idl
	$(WRAPPER) $(WRAPPER_FLAGS) --idl-file=intellirobot.idl
intellirobotStub.h : intellirobot.idl
	$(IDLC) $(IDLFLAGS) intellirobot.idl
	$(WRAPPER) $(WRAPPER_FLAGS) --idl-file=intellirobot.idl



BackInput.so: $(OBJS)
BackInput.o: BackInput.h  intellirobotStub.h
BackInputComp.o: BackInputComp.cpp BackInput.cpp BackInput.h  

intellirobotStub.o: intellirobotStub.cpp intellirobotStub.h

# end of Makefile

