I think I had not described context or purpose of my patch in last
mail. I'm going to explain the details about why the error occurs and
how the patch works. before and from I sent the patch, I have
inspected about them. So the detail was complicated but
interesting for me, I enjoyed it.
Well, this patch seems to be useful only on the old-fashiond Mac OS X
10.4.11, because no same error is not reported from anyone, and I'm an
only ghc user who uses Mac OS X 10.4.11. And ghc seemed to has quitted
to support the 10.4. This implies the patch should not be applied to
the repository. But if there are a few users like me, my patch and
report may be useful for (him|her).
In this report, we will make sure that what the error is, then trying
to write minimal reproducing code, in last, write appropriate patch.
First, What error has occured? It is occured when building
ghc-6.10.3. Main compilation successed such as compiler and library,
but building documents with haddock failed. From the error messages
below, when haddock runs gcc, the signal with SIGVTALRM is arrived to
gcc's child process (of cc1).
if ifBuildable/ifBuildable /Users/mate/work/ghc-6.10.3/packages
integer-gmp && [ -d integer-gmp/dist/doc/html/*/src/ ]; then cp
hscolour.css integer-gmp/dist/doc/html/*/src/; fi
if ifBuildable/ifBuildable /Users/mate/work/ghc-6.10.3/packages
base; then \
cd base && /Users/mate/work/ghc-6.10.3/libraries/cabal-
bin /usr/local/ghc-6.10.1/bin/ghc /Users/mate/work/ghc-6.10.3/
libraries/bootstrapping.conf 1.6.0.3 haddock --html-location='../$pkg' \
--hyperlink-source --with-
haddock=/Users/mate/work/ghc-6.10.3/utils/haddock/install-inplace/bin/
haddock; \
fi
Preprocessing library base-4.1.0.0...
Running hscolour for base-4.1.0.0...
Preprocessing library base-4.1.0.0...
Running Haddock for base-4.1.0.0...
Warning: The documentation for the following packages are not
installed. No
links will be generated to these packages: rts-1.0
i686-apple-darwin8-gcc-4.0.1: Internal error: Virtual timer
expired (program cc1)
Please submit a full bug report.
See URL:http://developer.apple.com/bugreporter for instructions.
make: *** [doc.library.base] Error 1
Of course, this can be seen only when haddock runs gcc. So, how does
haddock invoke gcc? It uses process library that fork() process and
exec() command in posix environment. And what is the SIGVTALRM?
SIGVTALRM is sended to a process of haskell program with certain
interval by the timer. It used for the scheduler in ghc's rts.
So, I could reproduce it with c (not haskell, unfortunately). Here is
the code.
#include
Hi,
I have a patch to process 1.0.1.1. If this patch is considered to be useful, Please apply.
This patch solves strange haddock death, in Mac OS X 10.4.11 with intel CPU. Details are described in http://www.nabble.com/6.10.3- prerelease-td23346957.html
Thanks, Hashimoto
<1242387095.dpatch>