[Expat-discuss] Don't want wrapper scripts.

Carlos Atabales catabales at hotmail.com
Fri Apr 22 00:08:54 CEST 2005


default makefile write wrapper scripts, not binaries programs.
this are the firsts line in a program.
# The outline program cannot be directly executed until all the libtool
# libraries that it depends on are installed.
#
# This wrapper script should never be moved out of the build directory.
# If it is, it will not operate correctly.
it's the solution a yuor problems....

CC=cc
FLAGS= -L../lib -I../lib
LIBS= -lexpat
outline: outline.c
        $(CC) $(FLAGS) -o outline outline.c $(LIBS)

clean:
        rm outline outline.o
------------

this is examples in directory /home/catabales/expat-1.95.8/examples

[catabales at desarrollo examples]$ file outline
outline: Bourne shell script text executable

[catabales at desarrollo examples]$ more outline
#! /bin/sh

# outline - temporary wrapper script for .libs/outline
# Generated by ltmain.sh - GNU libtool 1.4.2 (1.922.2.53 2001/09/11 
03:18:52)
#
# The outline program cannot be directly executed until all the libtool
# libraries that it depends on are installed.
#
# This wrapper script should never be moved out of the build directory.
# If it is, it will not operate correctly.

# Sed substitution that helps us do robust quoting.  It backslashifies
# metacharacters that are still active within double-quoted strings.
Xsed='sed -e 1s/^X//'
sed_quote_subst='s/\([\\`\\"$\\\\]\)/\\\1/g'
.......etc

------------------------------------

I compile and install the library in one location and I compile and link my
programs in another.

I had problems at first, but now I know that my programs are correctly
compiling and linking in the library, because I copy the binaries to an
independant location and they run and work fine as expected.

However, Where I make my programs I still get the wrapper scripts in ./ and
the binaries in ./.lib

Here is a snippet of my makefile, but be aware there is more to make it
work right, I just think the change I may be able to make is probably
some-where in here.

SHELL = /bin/bash
srcdir = ../expat
top_builddir = ../expat
LIBRARY = $(srcdir)/libexpat.la
LIBTOOL = $(SHELL) $(top_builddir)/libtool
INCLUDES = -I$(srcdir)/lib -I.
CFLAGS = -g -O2 -Wall -Wmissing-prototypes -Wstrict-prototypes -fexceptions
-DHAVE_EXPAT_CONFIG_H
LTFLAGS = --silent
COMPILE = gcc $(CFLAGS) $(DEFS) $(INCLUDES)
LINK_EXE = $(LIBTOOL) $(LTFLAGS) --mode=link $(COMPILE) -o $@

etc...

Can any-one tell me how I might just generate the target binaries into ./
and not the wrapper scripts.

Many thanks in anticipation,

Andrew.

_________________________________________________________________
MSN Amor: busca tu ½ naranja http://latam.msn.com/amor/



More information about the Expat-discuss mailing list