<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
  <META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
  <META NAME="GENERATOR" CONTENT="GtkHTML/3.26.0">
</HEAD>
<BODY>
<BR>
I have to make some assumptions here:<BR>
- the xcb/util repository is moving into five new repositories<BR>
- opportunities for reuse are being investigated<BR>
<BR>
<BR>
<BLOCKQUOTE TYPE=CITE>
    <TT><FONT COLOR="#737373">&gt; [0] <A HREF="http://cgit.freedesktop.org/~arnau/xorg-util-macros/commit/?id=28c561b3dd5729ffa511cfb3727dfff36477d80a">http://cgit.freedesktop.org/~arnau/xorg-util-macros/commit/?id=28c561b3dd5729ffa511cfb3727dfff36477d80a</A></FONT></TT><BR>
</BLOCKQUOTE>
I see a couple of reusable chunks, mainly the version compare and setting related xcb path.<BR>
The rest is miscellaneous and kills reusability. I would factor out these two chunks in separate macros.<BR>
Just like C code, it's more reusable if it does only one thing and has no side-effects.<BR>
<BR>
It remains to be seen if either of those are reusable by non-xcb packages (libX11?). I cannot answer that.<BR>
<BR>
There is a dependency on AX_* macros. You cannot rely on this macro being present on all platforms, being at the correct version or not being hacked. Xorg is a similar position with respect to AX_* macros. The only safe way is for any package using it to have it's own copy. This means there cannot be a copy in util-macros, for example.<BR>
<BR>
If you decide to have one of the 5 new repo to contain common code (macros, C code or whatever), or a separate repo, keep in mind the backward compatibility challenge. There will be a mix bag of versions in the field.<BR>
<BR>
<BLOCKQUOTE TYPE=CITE>
    <TT><FONT COLOR="#737373">&gt; [1] <A HREF="http://cgit.freedesktop.org/~arnau/xorg-util-macros/commit/?id=309b691da4d7a3c7e72f1b8a71c1fc18a7039cea">http://cgit.freedesktop.org/~arnau/xorg-util-macros/commit/?id=309b691da4d7a3c7e72f1b8a71c1fc18a7039cea</A></FONT></TT><BR>
    <BR>
</BLOCKQUOTE>
This one is reusable. Xorg packages do not check for the presence of m4. <BR>
This is the message I get if it missing:
<BLOCKQUOTE>
<PRE>
autoreconf: running: aclocal -I /home/nadon/xorg/src/share/aclocal 
autom4te: need GNU m4 1.4 or later: /usr/bin/m4
</PRE>
</BLOCKQUOTE>
<BR>
I am not sure autoconf will even get as far as to run your test. Perhaps it is not needed.<BR>
<BR>
That's all I can think of for now, not being familiar with xcb.
</BODY>
</HTML>