More minor editing. Hopefully clarified a few issues.

git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@2277 7ae35d74-ebe9-4afe-98af-79ac388436b8
Hamlib-1.2.7
Nate Bargmann, N0NB 2008-01-06 14:38:37 +00:00
rodzic 109af84b52
commit b832b4bf10
1 zmienionych plików z 174 dodań i 143 usunięć

Wyświetl plik

@ -49,56 +49,72 @@ I expect that IP, USB, and other connectivity will follow afterwards.
General Guidelines.
-------------------
0. The top level directory looks like this (Note, it has grown considerably).
0. The top level directory looks like this as of 06 Jan 2008
(Note, it has grown considerably).
[fillods@charybde hamlib]$ tree -d
~/test/hamlib $ tree -d -I CVS
.
|-- alinco
|-- aor
|-- bindings
|-- c++
|-- debian
|-- doc
| |-- html
| |-- man
| `-- sgml
|-- drake
|-- dummy
|-- easycomm
|-- flexradio
|-- fodtrack
|-- gnuradio
|-- icom
| |-- lib
| `-- test
|-- include
| `-- hamlib
|-- jrc
|-- kachina
|-- kenwood
|-- kit
|-- kylix
| `-- tests
|-- lib
|-- libltdl
|-- lowe
|-- macros
|-- microtune
|-- pcr
|-- perl
|-- racal
|-- rft
|-- rotorez
|-- rpcrig
|-- rpcrot
|-- sartek
|-- skanti
|-- src
|-- tapr
|-- tentec
|-- tests
| `-- html
| |-- config
| |-- rigctl.test
| |-- testbcd.test
| |-- testfreq.test
| `-- testloc.test
|-- tuner
|-- uniden
|-- winradio
| `-- linradio
|-- wj
`-- yaesu
51 directories
1. Building
If you just want to recompile the library, please refer
to the INSTALL file. This document introduces hacking the code of Hamlib.
1.1 Obtaining sources: anonymous (pserver) cvs checkout
cvs -d:pserver:anonymous@hamlib.cvs.sourceforge.net:/cvsroot/hamlib login
@ -117,6 +133,7 @@ feel free to experiment) deletes empty directories (yes some do exist :-) )
and adds any new directories added to the repository since your last
checkout.
1.1.1 Obtaining more info on CVS
Check out the sourceforge page at https://sourceforge.net/cvs/?group_id=8305
@ -124,6 +141,7 @@ for more information about how to use the CVS repository of Hamlib.
A CVS manual is online at http://ximbiot.com/cvs/manual/
1.2. Requirements
Hamlib is entirely developed using GNU tools, under various Linux systems.
@ -191,7 +209,7 @@ following in the same parent directory of hamlib:
make install
This will keep the binary output files seperate from the source tree and aid
in development.
in development by reducing clutter in the source tree.
Once you've run autogen.sh, make sure you've got some recent config.guess and
config.sub (needed to guess your system type). Anything of at least year 2004
@ -262,45 +280,53 @@ So far, Hamlib has been tested successfully under the following systems:
2.5. Create mybackend/Makefile.am, mybackend.c mybackend.h
Use 'dummy' backend as a template.
Here are commands for the bourne shell.
Here are commands for the bourne shell:
$ automake mybackend/Makefile
$ CONFIG_HEADERS= CONFIG_LINKS= \
CONFIG_FILES=mybackend/Makefile ./config.status
$ CONFIG_HEADERS= CONFIG_LINKS= CONFIG_FILES=mybackend/Makefile ./config.status
make in topdir to rebuild all
2.6. Commit your work:
2.6. Commit your work (developer access to Hamlib CVS required):
$ cvs add mybackend
$ cd mybackend
$ cvs add Makefile.am mybackend.c mybackend.h
$ cvs commit -m "Initial release" Makefile.am mybackend.c mybackend.h
Note: The `-m' switch passes a short message to the CVS repository
upon a commit. If a longer message is desired, do not use the
`-m' option. The editor specified in the EDITOR or VISUAL
environment variables will be started where a more detailed message
may be composed.
3. How to add a new model to and existing backend
3.1. make sure there's already a (unique) ID for the model to be added
in include/hamlib/riglist.h
3.2. locate the existing backend
3.3. Clone the most similar model in the backend
3.4. Add the new C file to the _SOURCES variable
of the backend's Makefile.am
3.5. Add "extern const struct rig_caps <mymodel>_caps;" to mybackend.h
3.6. In initrigs_<mybackend> of mybackend.c,
add "rig_register(&<mymodel>_caps);"
3.7. Run make if you have dependencies, or the following to regenerate
the makefile.
3.7. Run `make' if you have dependencies, or the following to regenerate
the makefile:
$ automake mybackend/Makefile
$ CONFIG_HEADERS= CONFIG_LINKS= \
CONFIG_FILES=mybackend/Makefile ./config.status
$ CONFIG_HEADERS= CONFIG_LINKS= CONFIG_FILES=mybackend/Makefile ./config.status
make in topdir to rebuild all
Run `make' in topdir to rebuild all.
3.8. Commit your work (once tests are satisfactory):
$ cd mybackend
$ cvs add mymodel.c
$ cvs commit -m "added <mymodel> to <mybackend>" \
Makefile.am mybackend.c mybackend.h mymodel.c
$ cvs commit -m "added <mymodel> to <mybackend>" Makefile.am mybackend.c mybackend.h mymodel.c
Note: See Note in section 2.6 above.
4. Read README.betatester to test the new backend/model.
@ -332,6 +358,7 @@ this. The error checking is removed for simplicity.
Starting points (not exhaustive):
gmfsk, gpredict, grig, klog, kontakt, ktrack, xlog, xtlf
8. Contributing code
8.1 License
@ -354,12 +381,14 @@ this. The error checking is removed for simplicity.
Patches should take care of portability issues.
Keep in mind Hamlib has to run under:
* various Linux's
* NetBSD, FreeBSD
* MacOS X
* Windows: MinGW/Cygwin, and VisualC++ support for rig.h
Hamlib should also compile with the following common compilers:
* gcc-2.9x (most likely deprecated)
* gcc-3.0 and gcc-3.2+ (nearly deprecated?)
* gcc-4.x and newer
@ -367,6 +396,7 @@ this. The error checking is removed for simplicity.
* C++ compiler against rig.h, riglist.h, rotator.h
Portability issues to watch:
* little vs. big endian systems (use shifts or adhoc functions)
* 64 bit int: avoid them in API
* printf/scanf of 64bit int: use PRIll and SCNll
@ -398,6 +428,7 @@ this. The error checking is removed for simplicity.
the Hamlib approach (c.f. previous section on submitting a patch).
Then you'll be able to commit by yourself to the backend you have
maintainance of. Please follow the rules hereunder:
* Always keep the CVS repository in a compilable state.
* Follow the coding guidelines
* Touching the frontend (files in src/ and include/hamlib) always