Compiler Problems

A forum for feature requests/discussions and user submitted patches that improve MQ2

Moderator: MacroQuest Developers

|| Napolion ||
a ghoul
a ghoul
Posts: 96
Joined: Sat Dec 28, 2002 7:45 am

Better if I hade a EXE file

Post by || Napolion || » Sun Mar 16, 2003 4:57 pm

I still have a problem

Code: Select all

Linking...
   Creating library Debug/eqlib.lib and object Debug/eqlib.exp
LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main
Debug/eqlib.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.

eqlib.exe - 2 error(s), 62 warning(s)
I did look true this post, and did include the CINTERFACE under Preprocessor (step #5)
Did all others steps too, but it wont compile.
Have the new SDK os it's not there. Did compile Detours too and include it to project (step #1 and #8)

I am using VC6 under winXP on a Atlon 2000+

Anyone have a clue ?

Gengis
a ghoul
a ghoul
Posts: 116
Joined: Wed Aug 14, 2002 7:46 pm

Post by Gengis » Sun Mar 16, 2003 7:53 pm

You should be making eqlib.dll not eqlib.exe

User avatar
Morath
a lesser mummy
a lesser mummy
Posts: 41
Joined: Tue Oct 22, 2002 3:09 pm

Post by Morath » Sun Mar 16, 2003 8:45 pm

I downloaded Microsoft Visual Studio 6.0 and get this error when attempting to compile...

DSDEV.EXE - Application Error
The instruction "0x77f8622c" referenced memory at "0x54a83401". The memory could not be "read".
Any suggestions on what the problem is?

Morath

|| Napolion ||
a ghoul
a ghoul
Posts: 96
Joined: Sat Dec 28, 2002 7:45 am

Post by || Napolion || » Mon Mar 17, 2003 8:33 am

Thanx Gengis now it works.

Goby
orc pawn
orc pawn
Posts: 10
Joined: Thu Mar 20, 2003 4:35 pm

Post by Goby » Thu Mar 20, 2003 4:46 pm

Well i compiled everything finally but there is no icon in the taskbar when i start the program just a blank space.
The program IS running and everything seems to work when i'm playing eq.
The macroquest is active message is there and i can use the commands i used to use before, the modified /who and a buffs macro.
But its annoying not to have the icon there at the bottom and i can't exit mquest without using ctrl+alt+del to close it.
I've obviously done something wrong somewhere but don't know what :)

Mckorr
Developer
Developer
Posts: 2326
Joined: Fri Oct 18, 2002 1:16 pm
Location: Texas

Post by Mckorr » Thu Mar 20, 2003 5:08 pm

You don't have the resource (.rc) file set in there correctly.

Your source Macroquest subdirectory (c:\src-20030308\macroquest) should have two icon files in it and one macroquest.rc file. If any of those files isn't there you won't get the icons.

azwildfire
Contributing Member
Contributing Member
Posts: 72
Joined: Fri Jul 05, 2002 5:12 am
Location: Phoenix arizona
Contact:

Post by azwildfire » Fri Mar 21, 2003 2:23 pm

followed the directions exactly, when i compile i get this

Code: Select all

--------------------Configuration: EQLib - Win32 Debug--------------------
Compiling...
EQLib.cpp
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2447: missing function header (old-style formal list?)
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(1) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(2) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(14) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(15) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(17) : error C2008: '\' : unexpected in macro definition
C:\SRC-20030308\EQLib\EQLib.cpp(20) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(21) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(21) : warning C4067: unexpected tokens following preprocessor directive - expected a newline
C:\SRC-20030308\EQLib\EQLib.cpp(24) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(25) : error C2008: '\' : unexpected in macro definition
C:\SRC-20030308\EQLib\EQLib.cpp(26) : error C2017: illegal escape sequence
C:\SRC-20030308\EQLib\EQLib.cpp(27) : warning C4067: unexpected tokens following preprocessor directive - expected a newline
c:\program files\microsoft visual studio\vc98\include\winbase.h(101) : error C2017: illegal escape sequence
c:\program files\microsoft visual studio\vc98\include\winbase.h(101) : fatal error C1012: unmatched parenthesis : missing ')'
Error executing cl.exe.

EQLib.dll - 40 error(s), 2 warning(s)
any ides?

User avatar
dont_know_at_all
Developer
Developer
Posts: 5450
Joined: Sun Dec 01, 2002 4:15 am
Location: Florida, USA
Contact:

Post by dont_know_at_all » Fri Mar 21, 2003 2:57 pm

You screwed up the source.

Try again w/out modifying the source.

azwildfire
Contributing Member
Contributing Member
Posts: 72
Joined: Fri Jul 05, 2002 5:12 am
Location: Phoenix arizona
Contact:

Post by azwildfire » Fri Mar 21, 2003 5:13 pm

i didnt do anything to the source, that is just unzipping the file from the link provided

User avatar
dont_know_at_all
Developer
Developer
Posts: 5450
Joined: Sun Dec 01, 2002 4:15 am
Location: Florida, USA
Contact:

Post by dont_know_at_all » Sat Mar 22, 2003 1:52 pm

Get a fresh copy of winzip, a fresh copy of the source, delete the directory you were working in, and start again.

The first line of eqlib.cpp is a comment.

bladecurve
decaying skeleton
decaying skeleton
Posts: 6
Joined: Wed Mar 12, 2003 6:53 pm

Post by bladecurve » Sun Mar 23, 2003 8:50 pm

Mckorr wrote:Ack!

Detours is distributed by Microsoft. You can get it here: http://research.microsoft.com/sn/detours/

Download detours.exe, that is a self-extracting WinZip file. Run it (double click on it) and pick a temp directory to extract it to, say C:\temp.

Now, go to C:\temp, and delete the files in the LIB and INCLUDE subdirectory. Call up a command console (a command line, y'know, C:>).

Change to the SRC directory (C:\temp\src). Execute a make command, that's "nmake" if you have VC++. This will compile the source code in the SRC directory, and place detours.h in the empty INCLUDE directory, and detours.lib and detours.pdb in the LIB directory. Copy those files to your compilers LIB and INCLUDE directories.

The detours part of the code will now compile correctly.
ok how do i bring up a comand console are you talking about msdos or what this is very confusing becuase every step is vague

Mckorr
Developer
Developer
Posts: 2326
Joined: Fri Oct 18, 2002 1:16 pm
Location: Texas

Post by Mckorr » Sun Mar 23, 2003 9:08 pm

A "command console" is the old DOS command line, at least for our purposes.

In WinNT or WinXP, click Start, then Run. Type in "cmd" and hit OK. See the C:> in the new window? That window is a Command Console, also called a DOS window or DOS box.

In WinME or earlier, do the same thing as above but type in "command" instead of "cmd" (and yes, I know "command" works in XP as well....)

Oh, and the instructions are not vague, they assume some basic knowledge of how to use your computer for something beyond double clicking the little icons...."Icons" are those little pictures on your screen, just in case I was being vague.

Okay, so Mckorr should never post when it's late and he's tired....

User avatar
driftinsupra
Official loudmouth
Official loudmouth
Posts: 212
Joined: Tue Jan 28, 2003 9:25 pm

Post by driftinsupra » Mon Mar 24, 2003 2:31 am

Well, getting the detours part was the easy part. If you are having trouble there I would give up now. Getting the darn thing compiled is when it gets confusing. The detours part is easy

User avatar
ap50
a snow griffon
a snow griffon
Posts: 425
Joined: Sun Aug 18, 2002 2:29 pm

Post by ap50 » Mon Mar 24, 2003 6:41 am

Whenever I read something like this, it reminds me of a so-called real tech service call for a product called Word Perfect.. You young-un's probably don't remember it... :?
Actual dialogue of a former WordPerfect Customer Support employee:

"Ridge Hall computer assistant; may I help you?"
"Yes, well, I'm having trouble with WordPerfect."
"What sort of trouble?"
"Well, I was just typing along, and all of a sudden the words went away."
"Went away?"
"They disappeared."
"Hmm. So what does your screen look like now?"
"Nothing."
"Nothing?"
"It's blank; it won't accept anything when I type."
"Are you still in WordPerfect, or did you get out?"
"How do I tell?"
"Can you see the C: prompt on the screen?"
"What's a sea-prompt?"
"Never mind. Can you move the cursor around on the screen?"
"There isn't any cursor: I told you, it won't accept anything I type."
"Does your monitor have a power indicator?"
"What's a monitor?"
"It's the thing with the screen on it that looks like a TV. Does it have a little light that tells you when it's on?"
"I don't know."
"Well, then look on the back of the monitor and find where the power cord goes into it. Can you see that?"
"Yes, I think so."
"Great. Follow the cord to the plug, and tell me if it's plugged into the wall."
".......Yes, it is."
"When you were behind the monitor, did you notice that there were two cables plugged into the back of it, not just one?"
"No."
"Well, there are. I need you to look back there again and find the other cable."
"....... Okay, here it is."
"Follow it for me, and tell me if it's plugged securely into the back of your computer."
"I can't reach."
"Uh huh. Well, can you see if it is?"
"No."
"Even if you maybe put your knee on something and lean way over?"
"Oh, it's not because I don't have the right angle - it's because it's dark."
"Dark?"
"Yes -the office light is off, and the only light I have is coming in from the window."
"Well, turn on the office light then."
"I can't."
"No? Why not?"
"Because there's a power outage."
"A power... A power outage? Aha, Okay, we've got it licked now. Do you still have the boxes and manuals and packing stuff your computer came in?"
"Well, yes, I keep them in the closet."
"Good. Go get them, and unplug your system and pack it up just like it was when you got it. Then take it back to the store you bought it from."
"Really? Is it that bad?"
"Yes, I'm afraid it is."
"Well, all right then, I suppose. What do I tell them?"
"Tell them you're too focking stupid to own a computer."
[color=yellow][size=92][b]Just because you're paranoid, it doesn't mean everyone isn't out to get you![/b][/size][/color]

keflex
Contributing Member
Contributing Member
Posts: 11
Joined: Tue Mar 25, 2003 1:27 pm

Post by keflex » Tue Mar 25, 2003 2:34 pm

If anyone could help me, I would appreciate it greatly.

In trying to compile detours, I run nmake and get these errors:

Code: Select all

Command line warning D4002 : ignoring unknown option '/O'
detours.cpp
Command line warning D4002 : ignoring unknown option '/O'
disasm.cpp
Command line warning D4002 : ignoring unknown option '/O'
image.cpp
Command line warning D4002 : ignoring unknown option '/O'
firstexc.cpp
Command line warning D4002 : ignoring unknown option '/O'
creatwth.cpp
I'm assuming that those are non-critical, since it seems to continue compiling fine afterwards. However, further down, nmake ends with these errors:

Code: Select all

Command line warning D4025 : overriding '/W4' with '/W3'
iping_i.c
Command line warning D4025 : overriding '/W4' with '/W3'
iping_p.c
iping_p.c(85) : fatal error C1189: #error :  You need a Windows 2000 or later to
 run this stub because it uses these features:
NMAKE : fatal error U1077: 'cl' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'C:\PROGRA~1\MICROS~3\VC98\BIN\NMAKE.EXE' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'C:\PROGRA~1\MICROS~3\VC98\BIN\NMAKE.EXE' : return code '0x2'
Stop.
It still outputs detours.h, detours.lib and detours.pdb, but when I add those to my VC++6 directory and try to compile McKorr's MQ, I receive the same invalid DWORD functions that McKorr was having before compiling detours (which leads me to believe that the detours files weren't compiled correctly).

I'm at a total lost when it comes to programming/compiling, so if anyone can give me a hand, I would be grateful.

[edit]

I forgot to add that I am running Win2k SP3, so I'm not sure why I'm seeing the "you need Windows 2000 to run this stub" error when compiling detours.