Results 1 to 25 of 25

Thread: nmake question (newbie)

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222

    Unhappy

    trying to compile a file with nmake so i open a dos prompt and write c:\gdidemo\nmake then press enter cgidemo is the file that i want to build that dir contains the source code too and the makefile file and here is what error i get


    Microsoft (R) Program Maintenance Utility Version 6.00.8168.0
    Copyright (C) Microsoft Corp 1988-1998. All rights reserved.

    cl -c -W3 -DCRTAPI1=_cdecl -DCRTAPI2=_cdecl -nologo -D_X86_=1 -D_WINNT -
    D_WIN32_WINNT=0x0400 -D_WIN32_IE=0x0300 -DWINVER=0x0400 -DWIN32 -D_WIN32 -Z7 -O
    d -DNT -DWIN -DNOT_IMPLEMENTED gdidemo.c
    'cl' is not recognized as an internal or external command,
    operable program or batch file.
    NMAKE : fatal error U1077: 'cl' : return code '0x1'
    Stop.


    i m a nwebie to this stuff and maybe that quest do not belong here but though that this forum was the more appropriate one
    thnks

  2. #2
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    Did you run vcvars32.bat first? cl.exe is the compiler.
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    thats the file i m trying to complile i copy in the same dir nmake,ntwin32.mak,win32.mak and the files in the zip than i run nmake what i m doing worng how to compile that file?
    Attached Files Attached Files

  4. #4
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    Don't copy the program files into it, just open the .dsw file in developer studio and build it from there.

    If you don't have dev studio, make a NEW folder, put those files in it, and run (from the same command prompt) vcvars32.bat

    You can't "compile" cl.exe -- it IS the compiler
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    when i try to compile the project using vc i get these errors
    didemo.obj : error LNK2001: unresolved external symbol _UnregisterAppClass
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateAppWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _RegisterAppClass
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateMDIClientWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _DisplayDialogBox
    Gdidemo.obj : error LNK2001: unresolved external symbol _AboutDlgProc@16
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateBounceWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateDrawWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateMazeWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateXFormWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreatePolyWindow
    LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main
    Debug/Gdidemo.exe : fatal error LNK1120: 12 unresolved externals
    Error executing link.exe.

    Gdidemo.exe - 13 error(s), 0 warning(s)



    though that nmake doing something different

  6. #6
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    You need to make a new Win32 Application (not MFC) project, and add the source files you have to it. Then try recompiling.
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  7. #7

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    k i create a new win32app and add all the files i see in it the compile it k it says the compiler but i search all my h/d no gdidemo.exe nowhere

  8. #8
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    There should be a folder "Release" or "Debug" under the folder where you put the project.
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  9. #9

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    yes it is but contain nothing

  10. #10
    Frenzied Member CyberCarsten's Avatar
    Join Date
    Sep 1999
    Location
    Aalborg Ø, Denmark
    Posts
    1,544
    Try clicking on "Build"
    razor
    Software Engineer Student, Aalborg University, Denmark
    http://www.cs.auc.dk

    My email at AUC: will get a new email soon
    My website: http://www.razorsoftware.net


    Windows XP Pro/ Gentoo Linux (Laptop)
    Windows XP Pro (Home PC)

  11. #11
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    Here's a project for you:
    Attached Files Attached Files
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  12. #12

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    i did that and i m getting this asa respond on the debug window

    -------------------Configuration: gdidemo - Win32 Debug--------------------

    gdidemo.exe - 0 error(s), 0 warning(s)

  13. #13
    Frenzied Member CyberCarsten's Avatar
    Join Date
    Sep 1999
    Location
    Aalborg Ø, Denmark
    Posts
    1,544
    Then is should be compiled....
    razor
    Software Engineer Student, Aalborg University, Denmark
    http://www.cs.auc.dk

    My email at AUC: will get a new email soon
    My website: http://www.razorsoftware.net


    Windows XP Pro/ Gentoo Linux (Laptop)
    Windows XP Pro (Home PC)

  14. #14

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    no gdidemo.exe in none of my h/d

  15. #15
    Frenzied Member CyberCarsten's Avatar
    Join Date
    Sep 1999
    Location
    Aalborg Ø, Denmark
    Posts
    1,544
    I just tried compiling it, and I got the following errors:

    --------------------Configuration: Gdidemo - Win32 Debug--------------------
    Compiling...
    Gdidemo.c
    c:\temp\gdi\gdidemo.c(35) : warning C4028: formal parameter 1 different from declaration
    c:\temp\gdi\gdidemo.c(35) : warning C4028: formal parameter 2 different from declaration
    Linking...
    Gdidemo.obj : error LNK2001: unresolved external symbol _UnregisterAppClass
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateAppWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _RegisterAppClass
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateMDIClientWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _DisplayDialogBox
    Gdidemo.obj : error LNK2001: unresolved external symbol _AboutDlgProc@16
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateBounceWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateDrawWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateMazeWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreateXFormWindow
    Gdidemo.obj : error LNK2001: unresolved external symbol _CreatePolyWindow
    LIBCD.lib(crt0.obj) : error LNK2001: unresolved external symbol _main
    Debug/Gdidemo.exe : fatal error LNK1120: 12 unresolved externals
    Error executing link.exe.

    Gdidemo.exe - 13 error(s), 2 warning(s)
    razor
    Software Engineer Student, Aalborg University, Denmark
    http://www.cs.auc.dk

    My email at AUC: will get a new email soon
    My website: http://www.razorsoftware.net


    Windows XP Pro/ Gentoo Linux (Laptop)
    Windows XP Pro (Home PC)

  16. #16

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    yep thats was mention in the posts above can u please read them

  17. #17
    Frenzied Member CyberCarsten's Avatar
    Join Date
    Sep 1999
    Location
    Aalborg Ø, Denmark
    Posts
    1,544
    It works for me now...nice graphics!
    razor
    Software Engineer Student, Aalborg University, Denmark
    http://www.cs.auc.dk

    My email at AUC: will get a new email soon
    My website: http://www.razorsoftware.net


    Windows XP Pro/ Gentoo Linux (Laptop)
    Windows XP Pro (Home PC)

  18. #18

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    what a bug i think it was a bug
    i was compiling the project that parksie post at D:\Documents and Settings\Administrator\Desktop\1 and i always got back errors i compiled then on c:\temp and it worjked

    thnks guys

  19. #19
    Frenzied Member CyberCarsten's Avatar
    Join Date
    Sep 1999
    Location
    Aalborg Ø, Denmark
    Posts
    1,544
    Sure!
    razor
    Software Engineer Student, Aalborg University, Denmark
    http://www.cs.auc.dk

    My email at AUC: will get a new email soon
    My website: http://www.razorsoftware.net


    Windows XP Pro/ Gentoo Linux (Laptop)
    Windows XP Pro (Home PC)

  20. #20

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    but i would be interested to know the steps involved in changing the project from the form i post it to the form the parksie did

  21. #21
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    This is what I did:

    1. Delete the gdidemo.def file -- you don't need it since the linker does it automatically now
    2. Delete the previous project files
    3. Create a new "Win32 Application"
    4. Add all .c, .h, and .rc files to this project
    5. Build it
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  22. #22

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    please keep up with me for a little more don't seem to get it this is what i m doing copy all the files to a dir del the def,dsp,dsw files trying to create a new win32app in the some folder and i me getting the error that the workspace exists what else do i have to delete?

  23. #23
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    You shouldn't get that error Delete the Release and Build folders as well. You need to make sure that you actually create it IN that folder, rather than another folder inside it which VC has a tendency to do.
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

  24. #24

    Thread Starter
    Addicted Member
    Join Date
    Jul 2000
    Location
    didn't decide yet
    Posts
    222
    i m a newbie remember what these files r?reliese and build what ext?

  25. #25
    Monday Morning Lunatic parksie's Avatar
    Join Date
    Mar 2000
    Location
    Mashin' on the motorway
    Posts
    8,169
    Sorry, I'm tired

    It's the Release and Debug folders, if they're there.

    Okay. Step-by-step:
    1. Open VC++
    2. Make a new Win32 Application in a new folder
    3. Find the folder you made that in and copy the .c, .h, and .rc files into it.
    4. Add those files to the project
    5. Press the Build button (or hit Ctrl-F5)
    I refuse to tie my hands behind my back and hear somebody say "Bend Over, Boy, Because You Have It Coming To You".
    -- Linus Torvalds

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width