[prev in list] [next in list] [prev in thread] [next in thread]
List: mingw-users
Subject: Re: [Mingw-users] Handling autoconf configure scripts
From: Xochitl Lunde <Xochitl_Lunde () tripplite ! com>
Date: 2009-03-23 15:23:37
Message-ID: OF287F8F69.AE96D2FF-ON86257582.005359C9-86257582.00544DB5 () tripplite ! com
[Download RAW message or body]
This is a multipart message in MIME format.
This is a multipart message in MIME format.
--=_alternative 00544DB586257582_=
Content-Type: text/plain; charset="US-ASCII"
> I strive to set up my own Linux-hosted environment. I've read document
> available at:
>
> http://www.mingw.org/wiki/IncludePathHOWTO
>
> Now compiler finds all the headers I want, but let's take the step
> before - what should I do for autoconf-made configure, if I want for
> it to look at MinGW directories for headers and libraries? Is it even
> possible, since they often depend on pkgtool?
>
> Yes, I am aware that the way over it is to edit config.mak or
> configure script itself, but if there is more automatic way to handle
> it, I would be most happy to know.
Are you talking about 'configure.ac' maybe? You can make a file named
'configure.ac' and autoconf will take into account the rules you put into
configure.ac when generating configure. The file could have the following
lines for a C++ program.
AC_INIT(hello.cc)
AM_INIT_AUTOMAKE(hello,0.1)
AC_PROG_CC
AC_PROG_CXX
AC_OUTPUT(Makefile)
You could look at the list of macros here
http://sunsite.ualberta.ca/Documentation/Gnu/automake-1.5/html_node/automake_88.html
or
http://www.gnu.org/software/autoconf/manual/html_node/Autoconf-Macro-Index.html#Autoconf-Macro-Index.
In 'configure.ac' you could define a variable for your path to MinGW. You
could use AC_ARG_VAR or AC_ARG_WITH to specify the path on the command
line as a configure option, for example. Or you could just hardcode it
for initial test like this:
ac_path_mingw_incs="-I/whatever-path/mingw
-I${variable-top-path}/other-mingwpath -I../../another-mingw-path"
AC_SUBST(ac_path_mingw_incs)
Then in your 'makefile.am' for your application or library you could add:
AM_INCLUDES=$(ac_path_mingw_incs)
Does this look like what you were asking about?
Xochitl
--=_alternative 00544DB586257582_=
Content-Type: text/html; charset="US-ASCII"
<br><tt><font size=2><br>
> I strive to set up my own Linux-hosted environment. I've read document<br>
> available at:<br>
> <br>
> http://www.mingw.org/wiki/IncludePathHOWTO<br>
> <br>
> Now compiler finds all the headers I want, but let's take the step<br>
> before - what should I do for autoconf-made configure, if I want for<br>
> it to look at MinGW directories for headers and libraries? Is it even<br>
> possible, since they often depend on pkgtool?<br>
> <br>
> Yes, I am aware that the way over it is to edit config.mak or<br>
> configure script itself, but if there is more automatic way to handle<br>
> it, I would be most happy to know.<br>
</font></tt>
<br><tt><font size=2>Are you talking about 'configure.ac' maybe? You
can make a file named 'configure.ac' and autoconf will take into account
the rules you put into configure.ac when generating configure. The
file could have the following lines for a C++ program.</font></tt>
<br>
<br><tt><font size=3>AC_INIT(hello.cc)<br>
AM_INIT_AUTOMAKE(hello,0.1)<br>
AC_PROG_CC<br>
AC_PROG_CXX<br>
AC_OUTPUT(Makefile)</font></tt>
<br>
<br><tt><font size=2>You could look at the list of macros here \
http://sunsite.ualberta.ca/Documentation/Gnu/automake-1.5/html_node/automake_88.html \
or http://www.gnu.org/software/autoconf/manual/html_node/Autoconf-Macro-Index.html#Autoconf-Macro-Index.</font></tt>
<br>
<br><tt><font size=2>In 'configure.ac' you could define a variable for
your path to MinGW. You could use AC_ARG_VAR or AC_ARG_WITH to specify
the path on the command line as a configure option, for example. Or
you could just hardcode it for initial test like this:</font></tt>
<br>
<br><tt><font size=2>ac_path_mingw_incs="-I/whatever-path/mingw \
-I${variable-top-path}/other-mingwpath
-I../../another-mingw-path"</font></tt>
<br><tt><font size=2>AC_SUBST(ac_path_mingw_incs)</font></tt>
<br>
<br><tt><font size=2>Then in your 'makefile.am' for your application or
library you could add:</font></tt>
<br>
<br><tt><font size=2>AM_INCLUDES=$(ac_path_mingw_incs)</font></tt>
<br>
<br><tt><font size=2>Does this look like what you were asking about?</font></tt>
<br><tt><font size=2>Xochitl</font></tt><tt><font size=3> </font></tt>
--=_alternative 00544DB586257582_=--
------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
--
_______________________________________________
MinGW-users mailing list
MinGW-users@lists.sourceforge.net
This list observes the Etiquette found at
http://www.mingw.org/Mailing_Lists.
We ask that you be polite and do the same.
Most annoying abuses are:
1) Top posting
2) Thread hijacking
3) HTML/MIME encoded mail
4) Improper quoting
5) Improper trimming
_______________________________________________
You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic