Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Linux Tools Project » Autotools in Windows?(Is possible to make work Autotools in Windows?)
Autotools in Windows? [message #675804] Wed, 01 June 2011 15:08 Go to next message
Wilfredo  is currently offline Wilfredo Friend
Messages: 5
Registered: April 2011
Junior Member
Sorry for the double post but I put this question before in the CDT forum but I didn´t get any answer.
Regards
Wilfredo

Dear all
In spite that Autotools documentation says that Autotools (Autotools support for CDT (Incubation)) was developed to work only in Linux/Unix enviroment, I want to know if someone has been able to configure this plug-in in Windows.
I am using Eclipse in Windows XP and MinGW/Msys and some features work well but some not, for example:
If I try "Invoke Autoconf" option in the Eclipse environment in my project, nothing happens but if I try "autoconf" command in the Msys shell-command this works well.
If my project is already configured (aclocal ->autoconf ->automake)
and then try "Reconfigure Project" option I get the following messages

Generating Makefile in build directory: D:/workspace/Prueba

sh /D/workspace/Prueba/configure
checking build system type... i686-pc-mingw32
checking host system type... i686-pc-mingw32
checking target system type... i686-pc-mingw32
checking for a BSD-compatible install... /usr/bin/install -c
configure: error: unsafe absolute working directory name
checking whether build environment is sane...

Configuration failed with error

The same command works well in Msys shell
Re: Autotools in Windows? [message #676914 is a reply to message #675804] Mon, 06 June 2011 23:26 Go to previous messageGo to next message
Andrew Overholt is currently offline Andrew OverholtFriend
Messages: 55
Registered: July 2009
Member
Hi Wilfredo,

Support for Windows is actually going to be a part of our 0.8 release which is a part of Indigo (June 22). You can try a nightly build (on an Indigo base) now to see if there are issues:

http://download.eclipse.org/technology/linuxtools/updates-nightly

Thanks,

Andrew
Re: Autotools in Windows? [message #677113 is a reply to message #676914] Tue, 07 June 2011 15:43 Go to previous messageGo to next message
Jeff Johnston is currently offline Jeff JohnstonFriend
Messages: 215
Registered: July 2009
Senior Member
Doug Schaefer of the CDT project did some work in testing Autotools on Windows with mingW. He opened 3 bugs which were fixed for our 0.8 release. One of these has to do with always running the Autotools tools as scripts and not directly as commands. On Windows/Mac they are run using sh with the -c option. Another bug had to do with the PWD environment variable getting set on the build and causing the configure script problems. The PWD environment variable is not passed on when invoking the various autotools during the configuration builder step. With these bug fixes, Doug was able to get the plug-in working successfully on Windows. He did note that he needed to put MSYS and MinGW in his path before creating the project. He did this by setting C/C++ Build - Environment variables in Preferences so all projects get it by default.
Re: Autotools in Windows? [message #677261 is a reply to message #677113] Tue, 07 June 2011 23:22 Go to previous messageGo to next message
Wilfredo  is currently offline Wilfredo Friend
Messages: 5
Registered: April 2011
Junior Member
Thanks for the information. I have downloaded Eclipse Indigo as you suggest me and Autotools works better but still having problems, for example:
If I create a Hello Autotools C++ project, the only command working is: Project =>Built All
If I try another option, for example Reconfigure Action, I get:
An internal error occurred during: "Reconfigure Action".
org.eclipse.cdt.ui.CUIPlugin.startGlobalConsole()V

Also, Autotools generate a Vpath which is different if I generate the make file using Msys.
Regards
Wilfredo
Re: Autotools in Windows? [message #677566 is a reply to message #677261] Wed, 08 June 2011 20:31 Go to previous messageGo to next message
Jeff Johnston is currently offline Jeff JohnstonFriend
Messages: 215
Registered: July 2009
Senior Member
Hi Wilfredo,

I have asked Doug Shaefer to drop by and answer your questions. He is the one who got the Autotools plug-in working on Windows and can perhaps shed some light on set-up requirements. I will be happy to document the results in our Autotools docs/wiki pages.

Jeff
Re: Autotools in Windows? [message #681719 is a reply to message #675804] Thu, 09 June 2011 17:40 Go to previous messageGo to next message
Wilfredo  is currently offline Wilfredo Friend
Messages: 5
Registered: April 2011
Junior Member
Hello Andrew and Jeff and thanks your support in testing Autotools under Windows.
At first I downloaded "eclipse-cpp-indigo-M6-win32.zip" and test the "Hello World" example and got the error that I reported.
Next I installed the Photran support that contains C/C++ Development Tools and all options of Autotools started working fine.
But I tried to run "Buil All" command for the FlopCpp open source package (aviable in www coin-or org), the "configure" command works well but the "make" command fails after compiling a big part of the package. I have tried to find out why but I couldn´t.
The main difference form files generated using Msys was the path. Autotools under windows generate a full path while Msys generate a path that start from the point that we see in Msys shell.
Regards
Wilfredo

Re: Autotools in Windows? [message #684008 is a reply to message #681719] Tue, 14 June 2011 20:58 Go to previous message
Wilfredo  is currently offline Wilfredo Friend
Messages: 5
Registered: April 2011
Junior Member
Hi Jeff
I was tracing the error I got and I believed that I found where the problems is.
In the "configure" script of my package there is the following sentence:

#############################################################################
# Determine list of all Cgl subprojects #
#############################################################################

# In order to avoid that one has to update this configure.as and the
# Makefile.am whenever a new cut generator is added, we automatically
# determine the list of all subdirectories of src with Makefile
# (CGL_SUBDIRS), and also a list of all sublibraries relative to src
# (CGL_SUBLIBS) that can be used in the src/Makefile.am. (We still need
# to manually add the Makefile in the AC_CONFIG_FILES list below)1

AC_SUBST(CGL_SUBDIRS)
AC_SUBST(CGL_SUBLIBS)

curr_dir=`pwd`
cd $srcdir/src
for file in `find . -name Makefile.in`; do
if test $file != ./Makefile.in; then
newdir=`echo $file | sed -e s%/Makefile.in%% | sed -e s%^./%% `
CGL_SUBDIRS="$CGL_SUBDIRS $newdir"
CGL_SUBLIBS="$CGL_SUBLIBS $newdir/lib${newdir}.la"
fi
done
cd $curr_dir


This part of the scrip works well under Msys shell but under Eclipse (Indigo) it is skipped and an empty line is generated

---- Under Msys---
CGL_SUBDIRS=' CglAllDifferent CglClique bla bla bla ...

---- Under Eclipse Indigo ---
CGL_SUBDIRS=''

I hope this information will be useful.

Regards
Wilfredo
Previous Topic:Adding shared library like gtkmm
Next Topic:Linux Tools 0.8.0 available now as part of Indigo
Goto Forum:
  


Current Time: Thu Apr 18 05:39:28 GMT 2024

Powered by FUDForum. Page generated in 0.01912 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top