Original Post

I’ve gotten VBDE and gccVB downloaded and installed properly I think. It is probably foolish to try and figure out how to do the same thing two different ways: ie, through notepad++ and command line. But I want to really understand the build process for VB games.

VBDE is pretty awesome in how it’s self-contained but I’m not too familiar with makefiles so I’ve been trying to figure that stuff out. It seems like VBDE will compile from notepad++ as long as you have a makefile. Some demos do and some don’t. I think VBDE also wants projects saved in individual folders within the “projects” folder of VBDE and that way the linking with libgccvb works with a: include “../libgccvb/libgccvb.h”. As long as I’ve described the basic set up properly I think I can use VBDE once I’ve gotten a handle on editing makefiles.

When I try to use gccVB through cygwin I encounter some funky issues. I’ve looked through different makefiles for the exact commands to issue to v810-gcc but I always get the same string of errors. Most of the errors I get are all related to macros in the video.h and world.h files. Here’s a snippet of some of the compiler errors.

../libgccvb/video.h:31: warning: type defaults to ‘in’ in declaration of ‘VIP_REGS’
../libgccvb/video.h:31: conflicting types for ‘VIP_REGS’
../libgccvb/vip.h:37: previous declaration of ‘VIP_REGS’
../libgccvb/video.h:31: ‘b’ undeclared here (not in a function)
../libgccvb/video.h:31: warning data definition has no type of storage class
../libgccvb/video.h:31: stray ‘/’ in program

tron.c:39: warning: implicit declaration of function ‘vbSetWorld’

I use this line from the barebones makefile when trying to compile through cygwin and :

v810-gcc -Wall -nodefaultlibs -mv810 -xc -o $(TARGET).o $(TARGET).c
I’d like to know what all these options mean and why they are included. Any help would be greatly appreciated!

1 Reply

Yeti_dude wrote:
When I try to use gccVB through cygwin I encounter some funky issues. I’ve looked through different makefiles for the exact commands to issue to v810-gcc but I always get the same string of errors. Most of the errors I get are all related to macros in the video.h and world.h files. Here’s a snippet of some of the compiler errors.

../libgccvb/video.h:31: warning: type defaults to ‘in’ in declaration of ‘VIP_REGS’
../libgccvb/video.h:31: conflicting types for ‘VIP_REGS’
../libgccvb/vip.h:37: previous declaration of ‘VIP_REGS’
../libgccvb/video.h:31: ‘b’ undeclared here (not in a function)
../libgccvb/video.h:31: warning data definition has no type of storage class
../libgccvb/video.h:31: stray ‘/’ in program

tron.c:39: warning: implicit declaration of function ‘vbSetWorld’

These errors look like they might just be caused by a mismatch between the libgccvb version you have and the compiler you’re using. Hard to say for sure without seeing the code.

I use this line from the barebones makefile when trying to compile through cygwin and :

v810-gcc -Wall -nodefaultlibs -mv810 -xc -o $(TARGET).o $(TARGET).c
I’d like to know what all these options mean and why they are included. Any help would be greatly appreciated!

“v810-gcc –help” will explain most of these, and the manpage can handle the rest, but here’s a quick rundown:

“-Wall” means to enable all warnings.
“-nodefaultlibs” obviously prevents gcc from linking in the default libraries one would use on a desktop system.
“-m” specifies the “machine” type. In this case, it’s “v810”. I think it might be optional in the tools with the “v810-” prefix, but I’ve never tested it.
“-xc” just means to treat the input file as one containing “C” code, rather than trying to figure out what it contains from the file extension.
“-o ” specifies the output filename. Any other files specified are input files.

Hope that helps.

 

Write a reply

You must be logged in to reply to this topic.