summaryrefslogtreecommitdiff
path: root/hw/xfree86
diff options
context:
space:
mode:
authorEric Anholt <anholt@freebsd.org>2005-12-22 13:54:08 +0000
committerEric Anholt <anholt@freebsd.org>2005-12-22 13:54:08 +0000
commit2af7e94eab6847159a3439301ecc93c62a12b1a0 (patch)
tree1780eb819efe3d82bfb203aeade0c142becd1910 /hw/xfree86
parent0d7ec5c7d9b451066a079fe56bcc9722341a91ff (diff)
Adjust the rules for auto-generating some source files, so that they work
on both GNU make and FreeBSD's make.
Diffstat (limited to 'hw/xfree86')
-rw-r--r--hw/xfree86/dixmods/Makefile.am7
-rw-r--r--hw/xfree86/xaa/Makefile.am59
2 files changed, 35 insertions, 31 deletions
diff --git a/hw/xfree86/dixmods/Makefile.am b/hw/xfree86/dixmods/Makefile.am
index 1ed24fa94..623006079 100644
--- a/hw/xfree86/dixmods/Makefile.am
+++ b/hw/xfree86/dixmods/Makefile.am
@@ -111,12 +111,13 @@ libtype1_la_SOURCES = type1mod.c
libdixmods_la_SOURCES = $(top_srcdir)/mi/miinitext.c
-libxorgxkb_la_SOURCES = xkbVT.c xkbPrivate.c xkbKillSrv.c
+XKB_SOURCES = xkbVT.c xkbPrivate.c xkbKillSrv.c
+libxorgxkb_la_SOURCES = $(XKB_SOURCES)
libxtrap_la_LDFLAGS = -avoid-version
libxtrap_la_LIBADD = $(top_builddir)/XTrap/libxtrapmodule.la
libxtrap_la_SOURCES = xf86XTrapModule.c
-xkb%.c:
+$(XKB_SOURCES):
echo "#define XF86DDXACTIONS" > $@
- echo "#include \"$(top_srcdir)/xkb/ddx$*.c\"" >> $@
+ echo "#include \"$(top_srcdir)/xkb/ddx${@:xkb%=%}\"" >> $@
diff --git a/hw/xfree86/xaa/Makefile.am b/hw/xfree86/xaa/Makefile.am
index a2d819944..39f0155a6 100644
--- a/hw/xfree86/xaa/Makefile.am
+++ b/hw/xfree86/xaa/Makefile.am
@@ -1,11 +1,11 @@
-LSB_FIRST = l-xaaBitmap.c l3-xaaBitmap.c l-xaaStipple.c l3-xaaStipple.c \
- l-xaaTEGlyph.c
-MSB_FIRST = m-xaaBitmap.c m3-xaaBitmap.c m-xaaStipple.c m3-xaaStipple.c \
- m-xaaTEGlyph.c
-LSB_FIXED = lf-xaaBitmap.c lf3-xaaBitmap.c lf-xaaStipple.c lf3-xaaStipple.c \
- lf-xaaTEGlyph.c
-MSB_FIXED = mf-xaaBitmap.c mf3-xaaBitmap.c mf-xaaStipple.c mf3-xaaStipple.c \
- mf-xaaTEGlyph.c
+LSB_FIRST = l-xaaBitmap.c l-xaaStipple.c l-xaaTEGlyph.c
+LSB_3_FIRST = l3-xaaBitmap.c l3-xaaStipple.c
+MSB_FIRST = m-xaaBitmap.c m-xaaStipple.c m-xaaTEGlyph.c
+MSB_3_FIRST = m3-xaaBitmap.c m3-xaaStipple.c
+LSB_FIXED = lf-xaaBitmap.c lf-xaaStipple.c lf-xaaTEGlyph.c
+LSB_3_FIXED = lf3-xaaBitmap.c lf3-xaaStipple.c
+MSB_FIXED = mf-xaaBitmap.c mf-xaaStipple.c mf-xaaTEGlyph.c
+MSB_3_FIXED = mf3-xaaBitmap.c mf3-xaaStipple.c
POLYSEG = s-xaaLine.c s-xaaDashLine.c
libxaa_la_LDFLAGS = -avoid-version
@@ -19,44 +19,47 @@ libxaa_la_SOURCES = xaaInit.c xaaGC.c xaaInitAccel.c xaaFallback.c \
xaaFillPoly.c xaaWideLine.c xaaTables.c xaaFillArc.c \
xaaLine.c xaaDashLine.c xaaOverlay.c xaaOffscreen.c \
xaaOverlayDF.c xaaStateChange.c xaaPict.c $(POLYSEG) \
- $(LSB_FIRST) $(MSB_FIRST) $(LSB_FIXED) $(MSB_FIXED)
-s-%.c:
+ $(LSB_FIRST) $(MSB_FIRST) $(LSB_FIXED) $(MSB_FIXED) \
+ $(LSB_3_FIRST) $(MSB_3_FIRST) $(LSB_3_FIXED) $(MSB_3_FIXED)
+${POLYSEG}:
echo "#define POLYSEGMENT" > $@
- echo '#include "$(srcdir)/$*.c"' >> $@
-l-%.c:
+ echo '#include "$(srcdir)/${@:s-%=%}"' >> $@
+${LSB_FIRST}:
echo "#define LSBFIRST" > $@
- echo '#include "$(srcdir)/$*.c"' >> $@
-l3-%.c:
+ echo '#include "$(srcdir)/${@:l-%=%}"' >> $@
+${LSB_3_FIRST}:
echo "#define LSBFIRST" > $@
echo "#define TRIPLE_BITS" >> $@
- echo '#include "$(srcdir)/$*.c"' >> $@
-lf-%.c:
+ echo '#include "$(srcdir)/${@:l3-%=%}"' >> $@
+${LSB_FIXED}:
echo "#define LSBFIRST" > $@
echo "#define FIXEDBASE" >> $@
- echo '#include "$(srcdir)/$*.c"' >> $@
-lf3-%.c:
+ echo '#include "$(srcdir)/${@:lf-%=%}"' >> $@
+${LSB_3_FIXED}:
echo "#define LSBFIRST" > $@
echo "#define TRIPLE_BITS" >> $@
echo "#define FIXEDBASE" >> $@
- echo '#include "$(srcdir)/$*.c"' >> $@
-m-%.c:
+ echo '#include "$(srcdir)/${@:lf3-%=%}"' >> $@
+${MSB_FIRST}:
echo "#define MSBFIRST" > $@
- echo '#include "$(srcdir)/$*.c"' >> $@
-m3-%.c:
+ echo '#include "$(srcdir)/${@:m-%=%}"' >> $@
+${MSB_3_FIRST}:
echo "#define MSBFIRST" > $@
echo "#define TRIPLE_BITS" >> $@
- echo '#include "$(srcdir)/$*.c"' >> $@
-mf-%.c:
+ echo '#include "$(srcdir)/${@:m3-%=%}"' >> $@
+${MSB_FIXED}:
echo "#define MSBFIRST" > $@
echo "#define FIXEDBASE" >> $@
- echo '#include "$(srcdir)/$*.c"' >> $@
-mf3-%.c:
+ echo '#include "$(srcdir)/${@:mf-%=%}"' >> $@
+${MSB_3_FIXED}:
echo "#define MSBFIRST" > $@
echo "#define TRIPLE_BITS" >> $@
echo "#define FIXEDBASE" >> $@
- echo '#include "$(srcdir)/$*.c"' >> $@
+ echo '#include "$(srcdir)/${@:mf3-%=%}"' >> $@
-DISTCLEANFILES = $(POLYSEG) $(LSB_FIRST) $(LSB_FIXED) $(MSB_FIRST) $(MSB_FIXED)
+DISTCLEANFILES = $(POLYSEG) \
+ $(LSB_FIRST) $(LSB_FIXED) $(MSB_FIRST) $(MSB_FIXED) \
+ $(LSB_3_FIRST) $(LSB_3_FIXED) $(MSB_3_FIRST) $(MSB_3_FIXED)
sdk_HEADERS = xaa.h xaalocal.h xaarop.h xaaWrapper.h
EXTRA_DIST = xaacexp.h xaawrap.h xaaLine.c xaaDashLine.c \