Welcome to GameHourz.com!
FAQFAQ      ProfileProfile    Private MessagesPrivate Messages   Log inLog in

Compiling? (win32 with mingw)

 
   Game Forums (Home) -> Roguelike -> Nethack RSS
Next:  Role difficulty and number of ascensions  
Author Message
kcolrawyksthgin

External


Since: Mar 10, 2005
Posts: 10



(Msg. 1) Posted: Wed Feb 06, 2008 6:10 pm
Post subject: Compiling? (win32 with mingw)
Archived from groups: rec>games>roguelike>nethack (more info?)

Hi folks,

I've been trying to compile 3.4.3 using gcc and MinGW under WinXP. I've got
the TTY version working just fine, and I'll be very happy with that, but it
bugs me that I can't get the Windows/tiles version going. I've applied the
modification to rpcndr.h that I found on the wiki, which removed the issues
around redefining boolean, but now I get a bunch of linker errors along the
lines of the following:

======
o/options.o: In function `parseoptions':
E:/games/nh343win/source/patchbase3-4-3/src/../src/options.c:1714: undefined
reference to `load_keyboard_handler'
E:/games/nh343win/source/patchbase3-4-3/src/../src/options.c:2147: undefined
reference to `map_subkeyvalue'
o/restore.o: In function `mgetc':
E:/games/nh343win/source/patchbase3-4-3/src/../src/restore.c:1017: undefined
reference to `error'
======

I did a groups search on it, but I didn't find anything that looked helpful.
Not to mention that rolling-your-own Nethack on Windows seems relatively
rare. My C is rusty (and possibly cursed), so I don't dare go messing with
the source files blindly. Could someone who's been-there-done-that point me
in the right direction?

thanks in advance,

--
-b

1 5966142 ___-Wiz-Hum-Mal-Neu ascended to demigod-hood. 261 [361]
Displayed email address has been spamproofed, reverse username to deproof.

 >> Stay informed about: Compiling? (win32 with mingw) 
Back to top
Login to vote
ra

External


Since: Feb 06, 2008
Posts: 1



(Msg. 2) Posted: Wed Feb 06, 2008 10:02 pm
Post subject: Re: Compiling? (win32 with mingw) [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

kcolrawyksthgin wrote:
> Hi folks,
>
> I've been trying to compile 3.4.3 using gcc and MinGW under WinXP. I've got
> the TTY version working just fine, and I'll be very happy with that, but it
> bugs me that I can't get the Windows/tiles version going. I've applied the
> modification to rpcndr.h that I found on the wiki, which removed the issues
> around redefining boolean, but now I get a bunch of linker errors along the
> lines of the following:
>
> ======
> o/options.o: In function `parseoptions':
> E:/games/nh343win/source/patchbase3-4-3/src/../src/options.c:1714: undefined
> reference to `load_keyboard_handler'
> E:/games/nh343win/source/patchbase3-4-3/src/../src/options.c:2147: undefined
> reference to `map_subkeyvalue'
> o/restore.o: In function `mgetc':
> E:/games/nh343win/source/patchbase3-4-3/src/../src/restore.c:1017: undefined
> reference to `error'
> ======
>
> I did a groups search on it, but I didn't find anything that looked helpful.
> Not to mention that rolling-your-own Nethack on Windows seems relatively
> rare. My C is rusty (and possibly cursed), so I don't dare go messing with
> the source files blindly. Could someone who's been-there-done-that point me
> in the right direction?
>
> thanks in advance,
>
probably a library is not getting linked properly, it looks like you
have some nonstandard paths so maybe it gets built but the compilier can
never find it

Just a guess.

 >> Stay informed about: Compiling? (win32 with mingw) 
Back to top
Login to vote
chuckcar

External


Since: Jun 26, 2006
Posts: 184



(Msg. 3) Posted: Thu Feb 07, 2008 6:21 am
Post subject: Re: Compiling? (win32 with mingw) [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

kcolrawyksthgin <kcolrawyksthgin.RemoveThis@comcast.net> wrote in
news:fqpkq3t4jjbvq730836m30gd8948u1jesk@4ax.com:

> Hi folks,
>
> I've been trying to compile 3.4.3 using gcc and MinGW under WinXP.
> I've got the TTY version working just fine, and I'll be very happy
> with that, but it bugs me that I can't get the Windows/tiles version
> going. I've applied the modification to rpcndr.h that I found on the
> wiki, which removed the issues around redefining boolean, but now I
> get a bunch of linker errors along the lines of the following:
>
> ======
> o/options.o: In function `parseoptions':
> E:/games/nh343win/source/patchbase3-4-3/src/../src/options.c:1714:
> undefined reference to `load_keyboard_handler'
> E:/games/nh343win/source/patchbase3-4-3/src/../src/options.c:2147:
> undefined reference to `map_subkeyvalue'
> o/restore.o: In function `mgetc':
> E:/games/nh343win/source/patchbase3-4-3/src/../src/restore.c:1017:
> undefined reference to `error'
> ======
>
> I did a groups search on it, but I didn't find anything that looked
> helpful. Not to mention that rolling-your-own Nethack on Windows seems
> relatively rare. My C is rusty (and possibly cursed), so I don't dare
> go messing with the source files blindly. Could someone who's
> been-there-done-that point me in the right direction?
>
> thanks in advance,
>
I assume you are doing this due to a patch? Try compiling the source
*without* the patch applied, and if it works, well, you know who to talk
to...


--
(setq (chuck nil) car(chuck) )
 >> Stay informed about: Compiling? (win32 with mingw) 
Back to top
Login to vote
kcolrawyksthgin

External


Since: Mar 10, 2005
Posts: 10



(Msg. 4) Posted: Thu Feb 07, 2008 8:46 am
Post subject: Re: Compiling? (win32 with mingw) [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On Wed, 06 Feb 2008 18:10:34 -0800, kcolrawyksthgin
<kcolrawyksthgin DeleteThis @comcast.net> wrote:

>[snip]

Fixed... and man, is my flabber ghasted.

So what happened: the first error that happened during compiliation, the
first time i tried, was "unable to create directory o". So I dove into the
makefile and figured out where it wanted said directory and created it.

Turns out that if I rm that directory and let the makefile create it (which
apparently it now can *flummox*) tty builds perfectly, and the errors I was
getting with win32 are gone.

Of course, I still can't build win32, but that's thanks to having put in
hpmon. Isn't there an #ifdef I can wrap the hpmon code in so it doesn't build
if the compiler is building the Windows version? (I suspect the answer is
no.)


--
-b

1 5966142 ___-Wiz-Hum-Mal-Neu ascended to demigod-hood. 261 [361]
Displayed email address has been spamproofed, reverse username to deproof.
 >> Stay informed about: Compiling? (win32 with mingw) 
Back to top
Login to vote
chuckcar

External


Since: Jun 26, 2006
Posts: 184



(Msg. 5) Posted: Thu Feb 07, 2008 6:30 pm
Post subject: Re: Compiling? (win32 with mingw) [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

kcolrawyksthgin <kcolrawyksthgin.RemoveThis@comcast.net> wrote in
news:jmcmq39op2tbsbmjj3s39j5nv2irv19687@4ax.com:

> On Wed, 06 Feb 2008 18:10:34 -0800, kcolrawyksthgin
> <kcolrawyksthgin.RemoveThis@comcast.net> wrote:
>
>>[snip]
>
> Fixed... and man, is my flabber ghasted.
>
> So what happened: the first error that happened during compiliation,
> the first time i tried, was "unable to create directory o". So I dove
> into the makefile and figured out where it wanted said directory and
> created it.
>
> Turns out that if I rm that directory and let the makefile create it
> (which apparently it now can *flummox*) tty builds perfectly, and the
> errors I was getting with win32 are gone.
>
> Of course, I still can't build win32, but that's thanks to having put
> in hpmon. Isn't there an #ifdef I can wrap the hpmon code in so it
> doesn't build if the compiler is building the Windows version? (I
> suspect the answer is no.)
>
>
There *is* at least one variable that is defined if it's a win32
compile. I wouldn't try it though. My guess is that you didn't install
cygwin properly. This is a shell error, not a compilation error per se.


--
(setq (chuck nil) car(chuck) )
 >> Stay informed about: Compiling? (win32 with mingw) 
Back to top
Login to vote
kcolrawyksthgin

External


Since: Mar 10, 2005
Posts: 10



(Msg. 6) Posted: Thu Feb 07, 2008 6:30 pm
Post subject: Re: Compiling? (win32 with mingw) [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On Thu, 7 Feb 2008 18:30:10 +0100 (CET), chuckcar <chuck RemoveThis @nil.car> wrote:

>kcolrawyksthgin <kcolrawyksthgin RemoveThis @comcast.net> wrote in
>news:jmcmq39op2tbsbmjj3s39j5nv2irv19687@4ax.com:
>
>> On Wed, 06 Feb 2008 18:10:34 -0800, kcolrawyksthgin
>> <kcolrawyksthgin RemoveThis @comcast.net> wrote:
>>
>>>[snip]
>>
>> Fixed... and man, is my flabber ghasted.
>>
>> So what happened: the first error that happened during compiliation,
>> the first time i tried, was "unable to create directory o". So I dove
>> into the makefile and figured out where it wanted said directory and
>> created it.
>>
>> Turns out that if I rm that directory and let the makefile create it
>> (which apparently it now can *flummox*) tty builds perfectly, and the
>> errors I was getting with win32 are gone.
>>
>> Of course, I still can't build win32, but that's thanks to having put
>> in hpmon. Isn't there an #ifdef I can wrap the hpmon code in so it
>> doesn't build if the compiler is building the Windows version? (I
>> suspect the answer is no.)
>>
>>
>There *is* at least one variable that is defined if it's a win32
>compile. I wouldn't try it though. My guess is that you didn't install
>cygwin properly. This is a shell error, not a compilation error per se.

Oh? Which variable is that?

As far as cygwin... I didn't install it at all, just MinGW. I can build the
official sources just fine, and after rolling botl.c back to pre-hpmon
patching, I can build from the patched sources just fine. I've even got nifty
little batch files that switch in appropriate versions of botl.c and
makefile.gcc, as well as nuking that pesky o directory.
--
-b

1 5966142 ___-Wiz-Hum-Mal-Neu ascended to demigod-hood. 261 [361]
Displayed email address has been spamproofed, reverse username to deproof.
 >> Stay informed about: Compiling? (win32 with mingw) 
Back to top
Login to vote
chuckcar

External


Since: Jun 26, 2006
Posts: 184



(Msg. 7) Posted: Thu Feb 07, 2008 10:52 pm
Post subject: Re: Compiling? (win32 with mingw) [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

kcolrawyksthgin <kcolrawyksthgin RemoveThis @comcast.net> wrote in
news:p7kmq31db7hbg7matt5tck0bp4a1t3g3ui@4ax.com:

> On Thu, 7 Feb 2008 18:30:10 +0100 (CET), chuckcar <chuck RemoveThis @nil.car>
> wrote:
>
>>kcolrawyksthgin <kcolrawyksthgin RemoveThis @comcast.net> wrote in
>>news:jmcmq39op2tbsbmjj3s39j5nv2irv19687@4ax.com:
>>
>>> On Wed, 06 Feb 2008 18:10:34 -0800, kcolrawyksthgin
>>> <kcolrawyksthgin RemoveThis @comcast.net> wrote:
>>>
>>>>[snip]
>>>
>>> Fixed... and man, is my flabber ghasted.
>>>
>>> So what happened: the first error that happened during compiliation,
>>> the first time i tried, was "unable to create directory o". So I
>>> dove into the makefile and figured out where it wanted said
>>> directory and created it.
>>>
>>> Turns out that if I rm that directory and let the makefile create it
>>> (which apparently it now can *flummox*) tty builds perfectly, and
>>> the errors I was getting with win32 are gone.
>>>
>>> Of course, I still can't build win32, but that's thanks to having
>>> put in hpmon. Isn't there an #ifdef I can wrap the hpmon code in so
>>> it doesn't build if the compiler is building the Windows version? (I
>>> suspect the answer is no.)
>>>
>>>
>>There *is* at least one variable that is defined if it's a win32
>>compile. I wouldn't try it though. My guess is that you didn't install
>>cygwin properly. This is a shell error, not a compilation error per
>>se.
>
> Oh? Which variable is that?
>

I'd have to look at the include files mentioned in the install docs. I
don't write patches, so I have *no* idea.

> As far as cygwin... I didn't install it at all, just MinGW. I can
> build the official sources just fine, and after rolling botl.c back to
> pre-hpmon patching, I can build from the patched sources just fine.
> I've even got nifty little batch files that switch in appropriate
> versions of botl.c and makefile.gcc, as well as nuking that pesky o
> directory.

Are you using bash or "msdos"? I would use the former.



--
(setq (chuck nil) car(chuck) )
 >> Stay informed about: Compiling? (win32 with mingw) 
Back to top
Login to vote
mastercontrol

External


Since: Jan 23, 2006
Posts: 8



(Msg. 8) Posted: Fri Feb 08, 2008 4:11 am
Post subject: Re: Compiling? (win32 with mingw) [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On Feb 7, 11:46 am, kcolrawyksthgin <kcolrawyksth....RemoveThis@comcast.net>
wrote:
> On Wed, 06 Feb 2008 18:10:34 -0800, kcolrawyksthgin

> Of course, I still can't build win32, but that's thanks to having put in
> hpmon. Isn't there an #ifdef I can wrap the hpmon code in so it doesn't build
> if the compiler is building the Windows version? (I suspect the answer is
> no.)

There's a version of hpmon that works with the graphical version,
somewhere.
 >> Stay informed about: Compiling? (win32 with mingw) 
Back to top
Login to vote
Tony Crawford

External


Since: Oct 31, 2007
Posts: 8



(Msg. 9) Posted: Tue Feb 12, 2008 4:56 pm
Post subject: Re: Compiling? (win32 with mingw) [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On Thu, 07 Feb 2008 03:10:34 +0100, kcolrawyksthgin
<kcolrawyksthgin.RemoveThis@comcast.net> wrote:

> I've been trying to compile 3.4.3 using gcc and MinGW under WinXP. I've
> got
> the TTY version working just fine, and I'll be very happy with that, but
> it
> bugs me that I can't get the Windows/tiles version going.
Sorry to mention the obvious, but did you "make clean" in between the two?

Otherwise, all I know about the business is what it says here:

http://kuerbis.dnsalias.net/~tony/howto/nh-cygwin-mingw-howto.html


Tony

--
When we dance around drunk in our underwear,
we don't ask ourselves any questions.
--Sawaki Kôdô roshi
 >> Stay informed about: Compiling? (win32 with mingw) 
Back to top
Login to vote
rpresser

External


Since: Nov 15, 2007
Posts: 12



(Msg. 10) Posted: Wed Feb 13, 2008 8:42 pm
Post subject: Re: Compiling? (win32 with mingw) [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On Feb 8, 7:11 am, mastercont... DeleteThis @gmail.com wrote:
> On Feb 7, 11:46 am, kcolrawyksthgin <kcolrawyksth... DeleteThis @comcast.net>
> wrote:
>
> > On Wed, 06 Feb 2008 18:10:34 -0800, kcolrawyksthgin
> > Of course, I still can't build win32, but that's thanks to having put in
> > hpmon. Isn't there an #ifdef I can wrap the hpmon code in so it doesn't build
> > if the compiler is building the Windows version? (I suspect the answer is
> > no.)
>
> There's a version of hpmon that works with the graphical version,
> somewhere.

To the best of my knowledge, only the tty and the QT ports have hpmon-
like patches.
 >> Stay informed about: Compiling? (win32 with mingw) 
Back to top
Login to vote
Display posts from previous:   
Related Topics:
Compiling NH and S on Mac OS X 10.4 - I recently returned to NH after a couple year hiatus, and in the interim I had switched from my usual Solaris and Linux boxen to using Mac OS X on my laptop. I was dismayed to find that precompiled NH binaries assumed the Mac user's preference for a..

Fun(?) compiling nethack under vmware server - Ok. Just for fun I decided to try installing several Unix like operating systems on VMware Server on my home computer and compiling nethack on them and this is my report. I did this on Fedora 8 (linux) FreeBSD 6.3 Solaris 10 I haven't messed with..

rec.games.roguelike.nethack - 999 subscribers - (google groups) I found this amusing, at least. I'd say I was subscriber number 1000 but it doesn't seem to update instantly so I might have been beaten to it.

Wishing suggestions for an extinctionist wizard - Chaotic human wizard, gone as deep as the vally of death and currently camping on an altar on DL:21. This is the first character that im attempting extinctionism with, and im finding myself wondering what I want to wish for. RNG has blessed me with a 0....

YASD Ring of what?? - Being the newbie that I am, I decided to equip both the rigs I started with as a wizard. They gotta be good, right? Wrong! First move after checking my inventory, I Put on my Ring of Conflict. Next turn I move to pick up the gold next to me, but I don't....
   Game Forums (Home) -> Roguelike -> Nethack All times are: Ekaterinburg, Islamabad, Karachi, Tashkent (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum



[ Contact us | Terms of Service/Privacy Policy ]