> Hi, I am trying to compile and use outboard modules on Intel with Win2k
> using both
> the 4.0.9 cygwin release and the 4.1.1 Microsoft Visual C++
> version posted
> recently.
> I can compile a module (well it doesn't complain) using cygwin 1.1.1
> and the Makefile below.
For MSVC, you should be able to compile yur modules using Microsoft Visual
C/C++
6.0. The libraries included with DX 4.1.1 are for MSVC 6.0 SP3.
Create a project and add the userScreenObject.c ScreenObject.c,
add opendx\include to include PATH, and link to libDXlite.lib?
>However when I go to run a net which uses the
> module I get a "failed to send data to module"
> message from both distributions. Snippet from mdf file I load up is also
> below.
There is a batch file called mdf.bat, which might work to create *c from
*.mdf,
though not well tested.
>
> Any pointers would be appreciated (ok what I really want is a well
> documented example ;-),
Sorry... someone else might have an example for you. Looks like your module
is not loading. Do you have DXMODULES defines? I did not experiment
but MSVC compiled DX should be able to load cygwin compiled modules
and vice versa.
Suhaib
> Simon.
>
> MODULE ScreenObject
> CATEGORY U of M
> DESCRIPTION Turn an Object into a Screen Object
> OUTBOARD /usr/local/share/dx/modules/screen-cygwin.exe;
> INPUT Object; field or group or object; (none); Object to be made into
> a Screen Object
> INPUT Position; integer; 1; Final Screen Position
> INPUT Display; integer; 1; {-1, 0, 1} : Behind, Equal, In Front
> OUTPUT SObject; group; SOject
>
>
> FILES_ScreenObject = userScreenObject.o ScreenObject.o
> BASE = /usr/local/dx
> BIN = $(BASE)/bin
> CFLAGS = -O -Dcygwin -I$(BASE)/include
> LDFLAGS=-L$(BASE)/lib_cygwin
> OLIBS = -lDXlite -lm
> # create the necessary executable
> screen: $(FILES_ScreenObject) outboard.o
> $(CC) $(LDFLAGS) $(FILES_ScreenObject) outboard.o $(OLIBS) -o screen.exe
>
> # how to make the outboard main routine
> outboard.o: $(BASE)/lib/outboard.c
> $(CC) $(CFLAGS) -DUSERMODULE=m_ScreenObject -c $(BASE)/lib/outboard.c
>
> # make the user files
> userScreenObject.c: ScreenObject.mdf
> $(BIN)/mdf2c -m ScreenObject.mdf > userScreenObject.c
>