[Magic-dev] Re: CIF torture test
R. Timothy Edwards
tim.edwards at multigig.com
Wed Jan 25 10:04:14 EST 2006
Dear Michael,
> I tried 120 using gcc 4.1 (comes with FC5beta) and -O2 leads to same
> segment fault. So, this error in gcc appears to be semi-permanent.
> Can you test for gcc4.x and set -O0, or does this need to be done manually?
The "configure" script in the top-level directory calls the real configure
script in ths "scripts" subdirectory. The proper way to handle optimizer
flags, according to the autoconf documentation, is to set CFLAGS as an
environment variable before running configure (seems pretty stupid to
me, but then again it's only one of a long list of complaints I have
about autoconf). Because I have the indirect call to the real configure
script, I was able to add the CFLAGS setting there. I should have done
that long ago, but didn't think of that (in retrospect, obvious) solution.
> Also, at some point you will get complaints about the hard-wired X11
> path: /usr/X11R6/... Fedora has decided to "integrate" X11. Binaries
> are in /usr/bin and headers are in /usr/include/. So, the Depend files in
> graphics and utils need to be changed (or use the results of ./configure)
> so that the X11 .h files can be found.
The "Depend" files are only for the benefit of the developer, to note
which files must be recompiled when other files are modified. To that
end, dependencies on system files should not even show up in the
Depend file. From what I can glean from the documentation, the -MM
file passed to gcc probably did the right thing in gcc-3.0 and earlier,
but now gcc has some obscure (and incorrect) way of determining what
is a "system header file", and anything in the /usr/X11R6 path is
apparently NOT in that list. So I threw in some "sed" scripts to
patch up the gcc output, and the resulting Depend files should not
cause you problems any more.
> Changing the -O2 to -O0 and the X11 change produces a Magic that
> seems to run fine using gcc4.1 and the new X11.
The version which I believe should compile and run correctly on FC4
is posted as 7.3.121.
In addition to the FC4-compliance hacks, I also made a few other
changes to the CIF read-in that now causes the cif-torture.cif file
to produce what appears to be correct output to the extent that
magic is able to handle the input (no cell rotations allowed that are
not multiples of 90 degrees). A few things like rotated boxes and
roundflashes could be supported, but I doubt it is worth the effort.
---Tim
+--------------------------------+-------------------------------------+
| Dr. R. Timothy Edwards (Tim) | email: tim.edwards at multigig.com |
| MultiGiG, Inc. | web: http://www.multigig.com |
| 100 Enterprise Way, Suite A-3 | phone: (831) 621-3283 |
| Scotts Valley, CA 95066 | cell: (240) 401-0616 |
+--------------------------------+-------------------------------------+
More information about the magic-dev
mailing list