You need to install and configure these things for NLM development:
You might also want to download the nlm-examples package from my FTP site: ftp://ftp.penguin.cz/pub/users/mhi/nlm/ or ftp://ftp.funet.fi/pub/mirrors/ftp.penguin.cz/pub/users/mhi/nlm/.
Let's start with the NetWare server. You can use NetWare versions 3.X, 4.X or 5.X. NetWare 5 (or 5.1) three user "demo" version can be ordered from Novell Inc. for a few dollars. Don't be confused with word "demo", it's fully functional NetWare, except that it is limited to three users. By the way, this license can be upgraded online, at no cost, to five users. You might also try asking your local Novell partner for demo CDs (they may be free).
You need to recompile your kernel with "The IPX protocol" and "NCP file system support" options enabled. Don't forget to say YES to "NDS authentication support" if you are using the NDS. Then you must configure the IPX protocol and mount your NetWare server volumes. Make sure that you have installed the ncpfs package! I use this script:
#!/bin/sh ipx_interface delall ipx_interface add -p eth0 802.2 120 # Frame Ethernet_802.2, ipx net num 120 insmod ncpfs # I have NCPfs compiled as module ncpmount -U admin -S elf -P XYZ /nw # mount all ELF's volumes as /nw
For more information about configuring IPX and NCPFS, see the IPX-HOWTO.
I think that all modern Linuxes for the Intel x86 include gcc, which generates ELF32/i386 object files. If you have an older Linux distribution, it may use the a.out format instead of ELF. If your Linux doesn't use ELF, get and install a newer gcc.
The nlmconv(1) utility links object files to the NLM format. It is a standard part of GNU binutils, but unfortunately it is not included in current distributions (RedHat, SuSE, Debian, ...). Get the binutils sources from ftp.gnu.org, and compile them, or simply use the pre-compiled nlmconv from my nlm-kit package.
My nlm-kit package is avaliable from ftp://ftp.penguin.cz/pub/users/mhi/nlm/. It contains necessary files for NLM development. Extract it and run "make all"
and "make install"
. It will create the directory /usr/nwsdk/
and install all import files, object files and the nlmimp(1) utility.
Getting the NDK is easy:
You need these files from the NDK (all are available online at http://developer.novell.com/ndk/clib.htm:
It's a pity that all the files mentioned above are InstallShield Win32 executables. You must find some Windows machine to extract them and then copy the include files to /usr/nwsdk/include/
and documentation/samples to anywhere you want. The Novell License doesn't allow me to distribute include files or documentation with the nlm-kit.
Because the NDK include files don't work under Linux, you need to patch them manually by typing "make install-include" in the nlm-kit-X.Y/ directory.
You can access the NetWare server console directly (keyboard and monitor), using rconsole.exe (from dosemu), or using telnetd.nlm/Xconsole (you need X server for this).