# name_SOURCES = my.c files.c
# include $(top_srcdir)/Rules
-$(MODULE).o: $($(MODULE)_OBJECTS)
+if LINUX25
+
+# FIXME
+# need to be rewritten:
+# - bad hacking in lvfs/Makefile.am obdclass/Makefile.am
+# - .o -> .ko
+#
+basename=$(shell echo $< | sed -e 's/\.c//g' | sed -e 's/-//g' | sed -e 's/\.o//g' | sed -e 's/^.*\///g')
+AM_CPPFLAGS=-I$(top_builddir)/include -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -pipe -mpreferred-stack-boundary=2 -DKBUILD_MODNAME=$(MODULE) -DKBUILD_BASENAME=$(basename)
+
+$(MODULE).o: $($(MODULE)_OBJECTS) $($(MODULE)_DEPENDENCIES)
+ $(LD) -m $(MOD_LINK) -r -o $(MODULE)_tmp.o $($(MODULE)_OBJECTS)
+ rm -f $(MODULE)_tmp.c
+ $(LINUX)/scripts/modpost $(LINUX)/vmlinux $(MODULE)_tmp.o
+ $(COMPILE) -UKBUILD_BASENAME -DKBUILD_BASENAME=$(MODULE) -c $(MODULE)_tmp.mod.c
+ $(LD) -m $(MOD_LINK) -r -o $(MODULE).o $(MODULE)_tmp.o $(MODULE)_tmp.mod.o
+
+else
+
+AM_CPPFLAGS=-I$(top_builddir)/include
+$(MODULE).o: $($(MODULE)_OBJECTS) $($(MODULE)_DEPENDENCIES)
$(LD) -m "`$(LD) --help | awk '/supported emulations/ {print $$4}'`" -r -o $(MODULE).o $($(MODULE)_OBJECTS)
+endif
+
+
tags:
rm -f $(top_srcdir)/TAGS
+ ETAGSF=`etags --version | grep -iq exuberant && \
+ echo "-I __initdata,__exitdata,EXPORT_SYMBOL"`; \
+ find $(top_srcdir) -name '*.[hc]' | xargs etags $$ETAGSF -a
+
rm -f $(top_srcdir)/tags
- find $(top_srcdir)/../portals -name '*.[hc]' | xargs etags -a
- find $(top_srcdir) -name '*.[hc]' | xargs etags -a
- find $(top_srcdir)/../portals -name '*.[hc]' | xargs ctags -a
- find $(top_srcdir) -name '*.[hc]' | xargs ctags -a
+ CTAGSF=`ctags --version | grep -iq exuberant && \
+ echo "-I __initdata,__exitdata,EXPORT_SYMBOL"`; \
+ find $(top_srcdir) -name '*.[hc]' | xargs ctags $$CTAGSF -a