CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 12 of 12
  1. #1
    Join Date
    Jul 2009
    Posts
    6

    Makefile in MS Visual Studio 2008

    Hi,
    I am new to C/C++ and MS Visual Studio 2008. I have a program written in c that I would like to compile. The program comes with many header files and other c scripts but also a MakeFile. I would like to run the MakeFile to just compile the program and then begin modifying the main script to go from there. How do I compile or run a MakeFile using MS Visual Studio 2008.

    Thanks
    Lefti

  2. #2
    GCDEF is offline Elite Member Power Poster
    Join Date
    Nov 2003
    Location
    Florida
    Posts
    12,635

    Re: Makefile in MS Visual Studio 2008

    You can open the makefile and VC will create a project out of it.

  3. #3
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,396

    Re: Makefile in MS Visual Studio 2008

    Quote Originally Posted by lefti View Post
    ... and other c scripts
    There is no such a thing like C script. There is a C code.
    Victor Nijegorodov

  4. #4
    Join Date
    Nov 2000
    Location
    Voronezh, Russia
    Posts
    6,620

    Re: Makefile in MS Visual Studio 2008

    How do I compile or run a MakeFile using MS Visual Studio 2008.
    Building on the Command Line
    Ultimately NMAKE is what you look for.
    Best regards,
    Igor

  5. #5
    Join Date
    Jul 2009
    Posts
    6

    Re: Makefile in MS Visual Studio 2008

    If I have a MakeFile can I load it through the IDE? It would be nice to view all files that are part of the MakeFile or part of the project. This way I could edit files, test, debug. I suppose I can do this command line but I am more used to IDE's in general. Just see what you guys think about this.

    Lefti

  6. #6
    Join Date
    Feb 2002
    Posts
    4,640

    Re: Makefile in MS Visual Studio 2008

    Quote Originally Posted by lefti View Post
    If I have a MakeFile can I load it through the IDE? It would be nice to view all files that are part of the MakeFile or part of the project. This way I could edit files, test, debug. I suppose I can do this command line but I am more used to IDE's in general. Just see what you guys think about this.

    Lefti
    See post #2...

    Viggy

  7. #7
    Join Date
    Jul 2009
    Posts
    6

    Re: Makefile in MS Visual Studio 2008

    Ok I opened the MakeFile in VS now what do I do. I do not see a way to run/compile the MakeFile? Thanks

  8. #8
    Join Date
    Feb 2002
    Posts
    4,640

    Re: Makefile in MS Visual Studio 2008

    Use "File"->"Open Project/Solution"

    Viggy

  9. #9
    Join Date
    Jul 2009
    Posts
    6

    Re: Makefile in MS Visual Studio 2008

    When I do File->Open->Project/Solution it looks for certain file extensions and I do not have any of those. When I loaded the MakeFile it did not create a project or anything like that. Am I missing something here. Thanks

    Lefti

  10. #10
    GCDEF is offline Elite Member Power Poster
    Join Date
    Nov 2003
    Location
    Florida
    Posts
    12,635

    Re: Makefile in MS Visual Studio 2008

    Quote Originally Posted by lefti View Post
    When I do File->Open->Project/Solution it looks for certain file extensions and I do not have any of those. When I loaded the MakeFile it did not create a project or anything like that. Am I missing something here. Thanks

    Lefti
    I did it with a makefile and it asked me if I want to create a project.

  11. #11
    Join Date
    Jul 2009
    Posts
    6

    Re: Makefile in MS Visual Studio 2008

    Does your MakeFile have a special extension.

  12. #12
    GCDEF is offline Elite Member Power Poster
    Join Date
    Nov 2003
    Location
    Florida
    Posts
    12,635

    Re: Makefile in MS Visual Studio 2008

    Just a .mak file I got from one of our old C programs.

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

Featured