Re: Newbie Request for Help (make dist problem)

2003-12-09 Thread J. Scott Amort
On Tue, 2003-12-09 at 09:27, Tom Tromey wrote:
> Yeah, you can do this.  It's a bit more idiomatic to list header
> files in a _SOURCES somewhere.  They are ignored for purposes of
> compilation, but are distributed.

Thanks for the advice - I'll move the header files into the _SOURCES
list.

Best Regards,

Scott


signature.asc
Description: This is a digitally signed message part


Re: Newbie Request for Help (make dist problem)

2003-12-09 Thread Tom Tromey
> "Scott" == J Scott Amort <[EMAIL PROTECTED]> writes:

Scott> - include
Scott> - src
Scott>- subdir1
Scott>- subdir2
Scott> - extra
Scott> - build
Scott>- src

Scott> The configure.ac, Makefile.am, etc. files are located in the
Scott> src subdirectory of the build directory at the bottom (nothing
Scott> platform specific is therefore in the top level directory).

Automake assumes that your top-level directory will have a
Makefile.am...

Scott> However, the problem lies
Scott> when trying to make dist.  It copies all of the include, src and extra
Scott> directories into the build directory and only makes a tar.gz of the
Scott> files that were originally in the build...src directory (i.e. configure,
Scott> configure.ac, etc.).  None of the source files make it into the
Scott> archive.  Why is this happening?

This is fallout from that assumption.

Scott> Additionally, it seems I would also
Scott> need to put the header files into the distribution, so I added:
Scott> EXTRA_DIST = \
Scott>$(ISRC)/header1.h \
Scott>$(SSRC)/header2.h

Yeah, you can do this.  It's a bit more idiomatic to list header
files in a _SOURCES somewhere.  They are ignored for purposes of
compilation, but are distributed.

Tom




Newbie Request for Help (make dist problem)

2003-12-04 Thread J. Scott Amort
Hello All,

I am relatively new to the autoconf, automake, libtool tools, and am
converting a project over to using them.  I have a question relating to
creating a proper Makefile.am to run a 'make dist' from, and although I
have read through the online manuals numerous times, I can't quite
figure this one out.  I hope someone is able to lend a hand.

Here is a brief descriptor: for reasons beyond my control, the project
(a C++ cross platform library) is structured like so (i've just used
generic names to get the point across):

- include
- src
   - subdir1
   - subdir2
- extra
- build
   - src

The configure.ac, Makefile.am, etc. files are located in the src
subdirectory of the build directory at the bottom (nothing platform
specific is therefore in the top level directory).  Here is the
framework of the Makefile.am:

# source directories
SSRC = ../../src
ISRC = ../../include
ESRC = ../../extra

CFLAGS = -Wall -Wno-deprecated -I$(ISRC) -I$(SSRC) -I$(SSRC)/subdir1
-I$(SSRC)/subdir2 -I$(ESRC) -g -O3

lib_LTLIBRARIES = libtest.la

libtest_la_SOURCES = \
   $(SSRC)/filename1.cpp \
   $(SSRC)/subdir1/filename2.cpp \
   $(SSRC)/subdir2/filename3.cpp \
   $(ESRC)/filename4.cpp

libtest_la_LDFLAGS = -version-info 0:0:0

libtest_la_CPPFLAGS = $(CFLAGS)

This works fine in compiling and producing the library (comments on
improvements are always welcome, though!)  However, the problem lies
when trying to make dist.  It copies all of the include, src and extra
directories into the build directory and only makes a tar.gz of the
files that were originally in the build...src directory (i.e. configure,
configure.ac, etc.).  None of the source files make it into the
archive.  Why is this happening?  Additionally, it seems I would also
need to put the header files into the distribution, so I added:

EXTRA_DIST = \
   $(ISRC)/header1.h \
   $(SSRC)/header2.h

etc...

Again, all that happens is that these files get copied to the
build...src directory during a make dist, they do not end up in the
archive.

Can anyone help?  I suspect there is something important that I am
missing, or that it has to do with the unorthodox directory structure,
but it is currently beyond me to solve.  Many thanks.

Best regards,

Scott


signature.asc
Description: This is a digitally signed message part