[Q] How do I use Visual Studio?

Discussion in '3DS - Homebrew Development and Emulators' started by VegaRoXas, Aug 22, 2015.

  1. VegaRoXas
    OP

    VegaRoXas GBAtemp Regular

    Member
    290
    158
    Mar 29, 2015
    Gambia, The
    So I want to create homebrew with Visual Studio. But how do I do this? Using notepad++ isn't that nice imo.

    Please help :3
     
  2. laramie

    laramie GBAtemp Fan

    Member
    499
    162
    Dec 15, 2014
    United States
    You just open a new project and code from scratch just like notepad++ or any other text editor.
     
  3. VegaRoXas
    OP

    VegaRoXas GBAtemp Regular

    Member
    290
    158
    Mar 29, 2015
    Gambia, The
    But I can't press like f5 to build? That would be pretty nice.
    Anyways thanks :3
     
  4. laramie

    laramie GBAtemp Fan

    Member
    499
    162
    Dec 15, 2014
    United States
    sure thing.
     
  5. VegaRoXas
    OP

    VegaRoXas GBAtemp Regular

    Member
    290
    158
    Mar 29, 2015
    Gambia, The
    Well, is it possible to build the project with VS?
     
  6. laramie

    laramie GBAtemp Fan

    Member
    499
    162
    Dec 15, 2014
    United States
    Of course just open a new project and get coding. Then enjoy. ;)
     
  7. VegaRoXas
    OP

    VegaRoXas GBAtemp Regular

    Member
    290
    158
    Mar 29, 2015
    Gambia, The
    Maybe you don't understand my question. Or I don't understand your answer lol.
    I want to fully use the capabilities VS has, for example IntelliSense etc. But I already struggle at adding ctrulib to my project. I already set up devkitARM and so on, so I wanna use the makefile in Visual Studio. With VS this would be so much nicer.
     
  8. laramie

    laramie GBAtemp Fan

    Member
    499
    162
    Dec 15, 2014
    United States
    You can make the makefile, however it's just going to be code just like if you made a new text document and added the exact same code then renamed it just makefile with no extension. You can't "compile" a makefile because you don't compile one you just type it up is all. It's like a shortcut instead of typing out every command...
     
  9. VegaRoXas
    OP

    VegaRoXas GBAtemp Regular

    Member
    290
    158
    Mar 29, 2015
    Gambia, The
    Well I wrongly expressed myself. Sorry xD
    [​IMG]
    There are errors everywhere. Of course it is because VS does not find the ctrulib header files I think. I want VS to recognize them, and make me use features like Code Completion (IntelliSense).
     
  10. laramie

    laramie GBAtemp Fan

    Member
    499
    162
    Dec 15, 2014
    United States
    Well did you add the ctrlib to the VS lib in the settings?
     
  11. VegaRoXas
    OP

    VegaRoXas GBAtemp Regular

    Member
    290
    158
    Mar 29, 2015
    Gambia, The
    No I didn't. How do I do this? :3
     
  12. benjymous

    benjymous Member

    Newcomer
    14
    2
    Feb 26, 2015
    As far as compiling goes, just create a 'Makefile project' when you set up your VS project, and set the build command to be 'make' - this will run the DevkitPro make command and build your makefile, assuming it's at the root of your project.

    I'm in the middle of trying to get VS2015 usable too - I'll report back if I make any more progress.
     
  13. elhobbs

    elhobbs GBAtemp Advanced Fan

    Member
    782
    292
    Jul 28, 2008
    United States
    You can take a look at the solution for prboom3ds on github. It has a visual studio build setup with the proper make and intellisense settings. Iirc it is mostly in the nmake tab in the project settings. You need to point it at the devkitpro directories and add a few defines. It also pipes the output from make through sed so that the output window works.
     
    benjymous likes this.
  14. benjymous

    benjymous Member

    Newcomer
    14
    2
    Feb 26, 2015
    I take it that means it reformats the output so the errors are properly picked up, and the lines are clickable?
     
  15. elhobbs

    elhobbs GBAtemp Advanced Fan

    Member
    782
    292
    Jul 28, 2008
    United States
    So that the lines are clickable.
     
  16. elhobbs

    elhobbs GBAtemp Advanced Fan

    Member
    782
    292
    Jul 28, 2008
    United States
    Visual studio handles the intellisense differently then say right-clicking a header file and selecting open-in this situation it looks at the the solution paths (which are different then the intellisense paths). Essentially you need to remove most but not all of the default paths from most places.
     
  17. clank

    clank Advanced Member

    Newcomer
    84
    24
    Jan 24, 2015
    1
    2
    3
    4
    Done. For compiling, just select the option to use a makefile when creating the solution, as they've already told you.
     
  18. VegaRoXas
    OP

    VegaRoXas GBAtemp Regular

    Member
    290
    158
    Mar 29, 2015
    Gambia, The
    Thank you so much :33 Gonna try this asap :)
     
  19. elhobbs

    elhobbs GBAtemp Advanced Fan

    Member
    782
    292
    Jul 28, 2008
    United States
    As a note the nmake section is where the intellisense settings need updating.