[petsc-dev] c2html and sowing fail on windows.

Satish Balay balay at mcs.anl.gov
Wed Jul 11 13:04:11 CDT 2012


On Wed, 11 Jul 2012, Chetan Jhurani wrote:

> I'm trying to build the mercurial version of petsc
> on windows using very basic options.  It tries to
> configure c2html and sowing automatically.  I'm
> guessing that is because both packages say that
> worksonWindows and downloadonWindows, and since
> configure sees it is working in the hg repo.
> 
> However, c2html gives this error -
> Cannot build c2html. It requires either "flex"
> or "lex" in PATH. Please install flex and retry.
> 
> And building sowing gives this error -
> cl.exe  -I../../include -I../../include -c arch.c
> arch.c(22) : fatal error C1083: Cannot open include
> file: 'sys/utsname.h': No such file or directory
> 
> I'm not using GCC.
> 
> Of course, using "--with-sowing=0 --with-c2html=0"
> avoids the issue for now, but both the packages don't
> work on windows out of the box.

These packages need cygwin gcc/g++ installed [and flex for c2html]

For one - they don't work with MS compilers. And they don't have to
use the same compilers as ones PETSc is built with [as they are
separate binaries - and not linked with PETSc library]. Also its best
to avoid mpi compiler wrapers with them.

So there is extra complexity in configure to support them. [separate
configure options to specify these separate compilers?]. Instead of
always insisting on user specifying these separate compilers - PETSc
configure lets c2html configure and sowing configure to do its own
suitable compiler detection. [and if gcc/g++ exist - they get picked
up and used]

configure supports the following extra options to support sowing
compilers [but the same doesn't exist for c2html - so c2html.py
perhaps needs fixing]

  --download-sowing-cc=<prog>
  --download-sowing-cxx=<prog>
  --download-sowing-configure-options=<options>
etc..

Satish




More information about the petsc-dev mailing list