Discussion:
imake problems on a Windows 2000 setup
(too old to reply)
T***@infineon.com
2005-02-24 21:55:13 UTC
Permalink
I've come across the need to use imake to facilitate cross platform
building of an application. From what I've read, imake {should} work
on Windows, but I've had issues getting this to work appropriately.

First I tried building imake by itself on the Windows system. This was
nigh impossible, so I scrapped that idea.

My second attempt was to install Microsoft's SFU 3.5, which comes with
imake. This {almost} works, but imake spits out output which seems ok,
but after make depend it looks like it corrupts the #includes from the
imake process and re-outputs them, such as this:

# dependencies generated by makedepend
space/imake/imake/Imake.rules"

# 1458 "/dev/fs/H/Work/e_workspace/imake/imake/Imake.rules"


# 1684 "/dev/fs/H/Work/e_workspace/imake/imake/Imake.rules"

The output has anywhere from ~50 to 200+ blank lines between the
screwed up #includes.

Has anyone seen this behavior with imake before? More importantly,
does anyone know what causes it? It is repeatable with several
different versions of cpp.

Thanks in advance,

--Tracy Beck
Lew Pitcher
2005-02-25 00:39:17 UTC
Permalink
Post by T***@infineon.com
I've come across the need to use imake to facilitate cross platform
building of an application. From what I've read, imake {should} work
on Windows, but I've had issues getting this to work appropriately.
[snip]

I'm sorry, but this forum can't help you.

You see, the comp.windows.x.apps forum is for the discussion of applications
that use the X network protocol. This forum has nothing to do with Microsoft
Windows except perhaps discussing the very few X client applications
implemented on that platform.

Your question has nothing to do with X applications, and probably should be
asked in one of the comp.os.ms-windows.* newsgroups instead.

I'm sorry,


- --
Lew Pitcher

Master Codewright & JOAT-in-training | GPG public key available on request
Registered Linux User #112576 (http://counter.li.org/)
Slackware - Because I know what I'm doing.
Dan Espen
2005-02-25 02:01:16 UTC
Permalink
Post by T***@infineon.com
I've come across the need to use imake to facilitate cross platform
building of an application. From what I've read, imake {should} work
on Windows, but I've had issues getting this to work appropriately.
First I tried building imake by itself on the Windows system. This was
nigh impossible, so I scrapped that idea.
My second attempt was to install Microsoft's SFU 3.5, which comes with
imake. This {almost} works, but imake spits out output which seems ok,
but after make depend it looks like it corrupts the #includes from the
# dependencies generated by makedepend
space/imake/imake/Imake.rules"
# 1458 "/dev/fs/H/Work/e_workspace/imake/imake/Imake.rules"
# 1684 "/dev/fs/H/Work/e_workspace/imake/imake/Imake.rules"
The output has anywhere from ~50 to 200+ blank lines between the
screwed up #includes.
Has anyone seen this behavior with imake before? More importantly,
does anyone know what causes it? It is repeatable with several
different versions of cpp.
The blank lines out of cpp are normal.
That's not really Imake doing that.
I believe cpp is trying to keep the line
numbers right for the compiler.

Lew,

Imake is shipped with X11.
tgbeck
2005-02-25 14:56:52 UTC
Permalink
Thanks for your prompt responses. And yes, I debated as to which forum
this should belong in, but as there aren't really any imake resources
online that I could find and I've tapped out Paul DuBois' book on the
subject, I was hoping to find someone with the experience necessary in
the X community.

As for the blank lines being normal, I really don't think so. Firstly,
cpp should remove all preprocessor directives before they ever hit cc,
meaning that the path of an include should be gone, and the contents of
the include should be present. Also, most preprocessors collapse any
whitespace in their directives down to a single space, as opposed to
adding space. Also, imake {seems} like it's creating the imake.c
correctly, and then dropping alot of useless (and non-preprocessable)
output at the end of it, so that the preprocessor would be blameless.
And lastly, unfortunately, this whole imake environment works on an
HP-UX system without a hitch. I've tried imake with several versions
of cpp, so I don't think I've got a hosed version of cpp. I tried
recompiling imake to make it behave, but every compile on SFU comes up
with that behavior

Compiling imake native to windows would be the best choice, but I'm not
above using SFU to achieve the same result, if it's easier/possible
that way. I know that imake {has} been built for Windows before, but
there seems to be a significant dearth of information on the topic.
Dan Espen
2005-02-25 16:08:51 UTC
Permalink
Post by tgbeck
Thanks for your prompt responses. And yes, I debated as to which forum
this should belong in, but as there aren't really any imake resources
online that I could find and I've tapped out Paul DuBois' book on the
subject, I was hoping to find someone with the experience necessary in
the X community.
As for the blank lines being normal, I really don't think so. Firstly,
cpp should remove all preprocessor directives before they ever hit cc,
meaning that the path of an include should be gone, and the contents of
the include should be present. Also, most preprocessors collapse any
whitespace in their directives down to a single space, as opposed to
adding space. Also, imake {seems} like it's creating the imake.c
correctly, and then dropping alot of useless (and non-preprocessable)
output at the end of it, so that the preprocessor would be blameless.
And lastly, unfortunately, this whole imake environment works on an
HP-UX system without a hitch. I've tried imake with several versions
of cpp, so I don't think I've got a hosed version of cpp. I tried
recompiling imake to make it behave, but every compile on SFU comes up
with that behavior
You don't think so?

Do you know or are you describing the way you would like cpp to work?

Normally cpp output goes into the compiler.
Any diagnostics produced by the compiler need to reference
line numbers in the original source, not the cpp output.

I believe that is why you see "#line" directives added
and blank lines inserted.

Regardless of the reason, I know from experience that cpp always
adds blank lines. I've seen that with at least 8 different cpp
implementations.
Post by tgbeck
Compiling imake native to windows would be the best choice, but I'm not
above using SFU to achieve the same result, if it's easier/possible
that way. I know that imake {has} been built for Windows before, but
there seems to be a significant dearth of information on the topic.
I don't recall the problem you are having.
I can't see why the blank lines would be a problem.
T Beck
2005-02-28 15:01:00 UTC
Permalink
No, you're right. I was thinking about spaces and tabs {inside} of the
preprocessor directives. It does, in fact, add blank lines to help out
the compiler. It also adds these # {line number} file/path/to/include
lines to do some sort of aid in compiler line number recognition.
The real problem turns out to be imake not cleaning all of that up as
it is supposed to. I've broken down at this point, and I've been
looking through the imake code, hoping to find the failure.

But extra lines and this non-cleaned up input is a problem, as the
output of cpp is not valid for make without some imake tweaking.

Apologies for doubting the veracity of your previous statement

--T Beck
Dan Espen
2005-02-25 16:11:09 UTC
Permalink
Post by tgbeck
Thanks for your prompt responses. And yes, I debated as to which forum
this should belong in, but as there aren't really any imake resources
online that I could find and I've tapped out Paul DuBois' book on the
subject, I was hoping to find someone with the experience necessary in
the X community.
http://www.kitebird.com/mailman/listinfo/imake-talk
T Beck
2005-02-28 15:02:34 UTC
Permalink
I will definitely check out that list. Thanks for your help, Dan!

--T Beck

Loading...