How to make a module?

BlitzMax Forums/BlitzMax Programming/How to make a module?

For building modules, I always just use Ctrl-D in the IDE.

The "Module does not match commandline module", as you realised, occurs when you try a "normal" build of the module - that is, Ctrl-B or Ctrl-R - because a normal build creates an exe, not a module .a file.

Ths ""Cannot find interface for pub.mymodule" message is a bit of a pain. I've had it alot when creating modules. One thing I would definetly check is that you use the SAME case for the following :
The name of your .mod folder - "mymodule.mod"
The name of your .bmx file - "mymodule.bmx"
It seems to be important that these are of the same case - I decided to always make mine lowercase from now on. (Well, it is certainly important on Linux/Mac - and after spending an hour debugging bmk, that is what I found fixed my problem with that message)

The case of the import and module names (in your code) do not seem to matter so much... Just make sure you don't have any typos there.

Other than that, I can't think of any other reason it won't import.

HTH