Original Post

Hello,

I was looking to build the Mario VB 3.0.1 source to the game, since I can’t find that version anywhere. I have been able to find 3.0.0 game.

I have downloaded and installed cygwin, and downloaded the latest gccVB 2.95 Pre-compiled version. But I am lost as what to do next?

Do I copy the contents of the gccVB into the cygwin folder? Where do I place the source code for Mario VB 3.0.1 then?

and from cygwin do I just do a makefile that is with the Mario VB?

I am familiar with C and C++ but haven’t coded anything recently. Although I am looking to jump back into it.

Thanks!

40 Replies

The easiest way to get your dev environment up and running is like this (I’m assuming you are running windows):

1. Download GCCVB compiler
2. Extract all folders/files in the zip to C:\gccvb
3. Download reality boy
4. Extract all folders/files to a directory of your choosing. For easy access I just chose C:\RealityBoy
5. Download programmer’s notepad and install it.
6. Now follow the instructions on this page to setup programmer’s notepad with the commands for gccvb and realityboy. Make sure to use the same directories you installed them in.
7. Now open up some VB_GAME.c file in programmer’s notepad and hit F1 to compile and F2 to run it in reality boy. I’m not sure if it matters, but I keep all of my code inside the C:\gccvb\ folder somewhere.

That should be it! No cygwin, no compiling from source, easy. Now, I’m sure there are some shortcomings to using this version of gccvb, but for me it works fine.

Wow, thanks Vaughanabe13 for the detailed instructions, I am using your instructions now.

ok, I was able to build the example and the hello3 examples from the gccvb directory, but when I try to build mariovb (3.0.1) version, I get errors.

The errors are basically where in the mariovb.c file calls other files, for example: line 31 and Line 34 where it calls vbjae.h and objects.h

I’m able to find the objects.h file here:
c:\gccvb\mariovb\game\objects\objects.h

but can’t locate the vbjae.h file

I’m almost wondering though, since there isn’t a vbh file with the mariovb source, do I have to go the route of cygwin?

I could always ask for someone to build the vb game and send it to me, but I would prefer that I build it myself so I can hopefully get back in the coding game of C, and maybe make some progress on the mariovb game. So that is why I am trying to build the game.

Are you saying you don’t have the vbjae.h file, or that the compiler can’t find it?

Also, did you make sure to use “%d %n” in the Parameters field of the gccvb and reality_boy tools in programmer’s notepad?

I’m not very sure about the difference in using this compiler vs. the cygwin + 2.95 approach. If someone else could chime in and explain I would appreciate that as well.

There’s two ways:

A) Using the older version as Vaughanabe13 described
B) Using newer version like the precompiled 2.95 NVC version

You should definitely go for the second option, because the newer gccVB version are much more advanced. The old one doesn’t support interrupts or bitstring instructions for example.

You only have to:
1) Install Cygwin
2) Download gccVB 2.95 prec., unpack it and copy the files to /c/cygwin/usr/

Then to build Mario VB, you only have to execute the following in Cygwin to trigger the make script included in the Mario VB source (for this example, the Mario VB source lies in C:/marioVB/):

cd /cygdrive/c/marioVB/ && make

(Everything from memory, might’ve missed a detail)

What link are you using for GCC 2.95? I can only find links for 8.10 or something like that.

The “latest version” link from http://gccvb.planetvb.com/.

> can’t locate the vbjae.h file

You’re missing Jorgeche’s vbJAEngine.

KR155E wrote:

cd /cygdrive/c/marioVB/ && make

ok, I followed these steps, and I’m getting an error when I run the above command.

bash: make: command not found

I also did makefile since I saw that file the mariovb folder, but got a similar error.

The mariovb folder is on the root of C Drive, and I fully installed cygwin and then copied the gccvb files to the
cygwin/usr/local folder

Do you guys have any idea why cygwin isn’t finding the make or makefile command?

thanks for the help though, I feel as if I am 95% of the way there.

Triumph wrote:

… I’m getting an error …

bash: make: command not found

If you’re getting this error, then:

… I fully installed cygwin …

probably isn’t accurate…

By “fully” do you mean that you installed EVERY package in the cygwin installer, or that you “clicked through” the whole installer? You do actually have to pick the packages you need, because the base system only includes the shell and a few system utilities.

Run the installer again and when you get to the big list box, type “make” into the search box at the top, then expand the “Devel” item and click the word “skip” next to the “make” package. It should turn into a version number and the box in the “Bin?” column should be checked. You might also want to install GCC, binutils, etc. in case you want to brush up on your C skills by making non-VB programs (such as VB development utilities ;-)) or compiling a newer version of the gccVB cross-compiler.

Hope that helps!

*EDIT* Nevermind I figured out the answer to my question

  • This reply was modified 14 years, 3 months ago by Vaughanabe13.

KR155E wrote:
There’s two ways:

A) Using the older version as Vaughanabe13 described
B) Using newer version like the precompiled 2.95 NVC version

You should definitely go for the second option, because the newer gccVB version are much more advanced. The old one doesn’t support interrupts or bitstring instructions for example.

You only have to:
1) Install Cygwin
2) Download gccVB 2.95 prec., unpack it and copy the files to /c/cygwin/usr/

Then to build Mario VB, you only have to execute the following in Cygwin to trigger the make script included in the Mario VB source (for this example, the Mario VB source lies in C:/marioVB/):

cd /cygdrive/c/marioVB/ && make

(Everything from memory, might’ve missed a detail)

Chris, how do you compile code without a makefile using the newest 2.95 compiler in cygwin, such as the demo.c program from the dev wiki?

Just add a makefile, it’s as simple as:

all: 
v810-gcc -T/usr/local/v810/lib/vb.ld -O -I. demo.c -o demo.elf 
v810-objcopy -O binary demo.elf demo.vb

Don’t know if that’s all that’s necessary to make the demo code compile under the latest gccVB, though.

I thought as much. The problem with all this is information is so scattered. Almost all the information IS on the web somewhere (this site or readme’s or otherwise), but it’s all disorganized and cluttered and you have to take a piece here and a piece there and figure out how it all comes together. What we’re missing is a good step-by-step with FAQ’s and troubleshooting and all that. And the guides that we do have are somewhat out of date and sometimes they just make me more confused. 😯

You’re totally right, we really need a good tutorial which helps beginners step-by-step. That’s what I wanted the “Getting Started” paragraph of the Dev Wiki to become. But as you see, nobody ever got around to. Shouldn’t take too much work to create a guide actually…

RunnerPack wrote:

Triumph wrote:

… I’m getting an error …

bash: make: command not found

If you’re getting this error, then:

… I fully installed cygwin …

probably isn’t accurate…

By “fully” do you mean that you installed EVERY package in the cygwin installer, or that you “clicked through” the whole installer? You do actually have to pick the packages you need, because the base system only includes the shell and a few system utilities.

Run the installer again and when you get to the big list box, type “make” into the search box at the top, then expand the “Devel” item and click the word “skip” next to the “make” package. It should turn into a version number and the box in the “Bin?” column should be checked. You might also want to install GCC, binutils, etc. in case you want to brush up on your C skills by making non-VB programs (such as VB development utilities ;-)) or compiling a newer version of the gccVB cross-compiler.

Hope that helps!

Wow, I’m an idiot. Thanks for the help though. Yeah I clicked through it not selecting anything, when I thought that was a menu of what it was going to install.

Doh.

Thanks again.

At the top of the menu tree there is a button you can click to install all packages. You will know if you did it right because it takes a good chunk of time to install everything.

ok thanks everyone, I installed the packages I needed, and I still seem to be running into an issue.

When I run the make command this is what I get:

Creating object file for source/marioVB...
cpp: /vbjae.h: No such file or directory
make: *** [.make-release/source/marioVB.o] Error 1

I think the problem is with the location of the vbjaengine folder.

Do I need to put the vbjaengine in the mariovb folder?
so my dir structure would be:
c:\mariovb\vbjaengine ?

or do I need to build vbjaengine like I would mariovb, then place the output (libvbjae.a) into the mariovb folder somewhere? or am I missing something else?

From the Mario VB readme:

COMPILING ON WIN32
==================

Requirements:

· Minimal Linux environment (i.e: CygWin)

· GCCVB 2.95 for V810

1. Create an environment variable called VBJAENGINE which must point to the vbJaEngine’s folder.

2. To compile the execute the following command inside the game’s folder:

$ make

This will compile the engine and the game, the executable is placed in the output/ folder.

If you don’t want to mess with environment variables (which are kind of a hassle on windows alone, and then you get cygwin involved…) just edit the makefile and add the line:

VBJAENGINE = 

somewhere near the top. For example, if vbjae.h is in C:\javbengine\ it would be:

VBJAENGINE = /cygdrive/c/javbengine

Whenever I’m having “missing file” type errors while compiling, I try to track down what is pointing to said file(s) and where it’s looking for it/them. In this case, I looked in the makefile ;-).

Really excited to see what you do with the game! 😀

EDIT: Alright! Why do my posts always end up at the top of a new page?!? >:( 😛

Hey, KR155E, how about a “paginator” badge? 😉

 

Write a reply

You must be logged in to reply to this topic.