automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

CORBA IDL support revisited


From: Ossama Othman
Subject: CORBA IDL support revisited
Date: Tue, 5 Mar 2002 00:37:22 -0800
User-agent: Mutt/1.3.27i

Hi,

I have yet another approach for adding CORBA IDL support to Automake.
My approach is currently done entirely within a few Autoconf macros,
and via `config.status'.  Very preliminary (and not fully functional)
patches are attached.

The patches basically cause `config.status' to directly modify all
Makefiles that contain sources that end in ".idl" via Autoconf's
AC_CONFIG_COMMANDS.

The Autoconf macros run the IDL compiler with a simple test program in
a `conftest.d' directory, and determines what the prefixes (if any)
and suffixes are.  The macro that does this is itself
non-IDL-specific.  The detected suffixes are then stored in the
generated `config.status' file, at which point the commands added by
AC_CONFIG_COMMANDS will use them to generate Makefile targets/rules.

Here's sample `configure' output from the macros:

checking for prefixes and suffixes of `tao_idl' generated files... none,  C.cpp 
C.h C.i S.cpp S.h S.i

In this case, the `tao_idl' compiler was used but the macros are
IDL-compiler neutral.  They're infact language neutral.

A sample Makefile modified by the support I added is attached, too.  I
can send the 73K gzipped tarball containing the simple test case I've
been using to test the patches, if anyone is interested.

It is still missing rules that clean up the generated files (i.e. the
stubs and skeletons).  I can't seem to get the old-style suffix rules
to work either.  Obviously I'm doing something stupid with the latter
case, so any help is greatly appreciated as well as any other
feedback.  Note that there is alot of inefficient shell script code in
my patches due to the fact I couldn't figure out how to do things in
an elegant/efficient way (I'm not a shell script or regex guru).

Some other caveats:
- ".SUFFIXES" generation isn't completely foolproof since I still get
  some duplicates.
- The inadequate assumption that generated stubs and skeletons will be
  both be linked into a binary is made.  Needs improvement.
- May need to generate ".PRECIOUS" targets.
- Object files for stubs and skeletons must be explicitly added to the
  object file list (e.g. LDADD/LIBADD).
- Needs to be tested with Java.  I've only tested with C++.

Thanks,
-Ossama
-- 
Ossama Othman <address@hidden>
Distributed Object Computing Laboratory, Univ. of California at Irvine
1024D/F7A394A8 - 84ED AA0B 1203 99E4 1068  70E6 5EB7 5E71 F7A3 94A8

Attachment: rulegen.m4.gz
Description: Binary data

Attachment: Makefile.gz
Description: Binary data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]