I did that on sequence (build FANN library,
http://leenissen.dk/fann/ ) :
1. File->New Project->Dynamic Link Library (options: Do not create any files). Project named fann_dll (simple :-))
2. On Managment->Projects->Workspace->fann_dll->Add files. I've added *.c and *.h files.
3. Build->Rebuild.
The log is:
-------------- Build: default in fann_dll ---------------
Compiling: ..\..\include\doublefann.c
Compiling: ..\..\include\fann.c
Compiling: ..\..\include\fann_cascade.c
Compiling: ..\..\include\fann_error.c
Compiling: ..\..\include\fann_io.c
Compiling: ..\..\include\fann_train.c
Compiling: ..\..\include\fann_train_data.c
Compiling: ..\..\include\fixedfann.c
Compiling: ..\..\include\floatfann.c
Linking dynamic library: fann_dll.dll
.objs\include\fann.o(.text+0x0):fann.c: multiple definition of `fann_create_standard'
.objs\include\doublefann.o(.text+0x0):doublefann.c: first defined here
.objs\include\fann.o(.text+0xc9):fann.c: multiple definition of `fann_create_sparse'
.objs\include\doublefann.o(.text+0xc9):doublefann.c: first defined here
.objs\include\fann.o(.text+0x9a8):fann.c: multiple definition of `fann_create_shortcut'
.objs\include\doublefann.o(.text+0x9b7):doublefann.c: first defined here
.objs\include\fann.o(.text+0xdd7):fann.c: multiple definition of `fann_run'
.objs\include\doublefann.o(.text+0xdec):doublefann.c: first defined here
.objs\include\fann.o(.text+0x1a62):fann.c: multiple definition of `fann_randomize_weights'
.objs\include\doublefann.o(.text+0x1b58):doublefann.c: first defined here
.objs\include\fann.o(.text+0x1ad9):fann.c: multiple definition of `fann_print_connections'
.objs\include\doublefann.o(.text+0x1be3):doublefann.c: first defined here
.objs\include\fann.o(.text+0x1d65):fann.c: multiple definition of `fann_init_weights'
.objs\include\doublefann.o(.text+0x1e6f):doublefann.c: first defined here
.objs\include\fann.o(.text+0x2009):fann.c: multiple definition of `fann_print_parameters'
.objs\include\doublefann.o(.text+0x2113):doublefann.c: first defined here
.objs\include\fann.o(.text+0x23b0):fann.c: multiple definition of `fann_get_num_input'
.objs\include\doublefann.o(.text+0x24c0):doublefann.c: first defined here
.objs\include\fann.o(.text+0x23ef):fann.c: multiple definition of `fann_get_total_connections'
.objs\include\doublefann.o(.text+0x24ff):doublefann.c: first defined here
.objs\include\fann.o(.text+0x23bb):fann.c: multiple definition of `fann_get_num_output'
.objs\include\doublefann.o(.text+0x24cb):doublefann.c: first defined here
.objs\include\fann.o(.text+0x23c6):fann.c: multiple definition of `fann_get_total_neurons'
.objs\include\doublefann.o(.text+0x24d6):doublefann.c: first defined here
.objs\include\fann.o(.text+0xa4e):fann.c: multiple definition of `fann_create_shortcut_array'
.objs\include\doublefann.o(.text+0xa5d):doublefann.c: first defined here
.objs\include\fann.o(.text+0x2930):fann.c: multiple definition of `fann_allocate_connections'
.objs\include\doublefann.o(.text+0x2a4b):doublefann.c: first defined here
.objs\include\fann.o(.text+0x184e):fann.c: multiple definition of `fann_destroy'
.objs\include\doublefann.o(.text+0x1944):doublefann.c: first defined here
.objs\include\fann.o(.text+0x2832):fann.c: multiple definition of `fann_allocate_neurons'
.objs\include\doublefann.o(.text+0x294b):doublefann.c: first defined here
.objs\include\fann.o(.text+0x23fa):fann.c: multiple definition of `fann_allocate_structure'
.objs\include\doublefann.o(.text+0x250a):doublefann.c: first defined here
.objs\include\fann.o(.text+0x29c1):fann.c: multiple definition of `fann_seed_rand'
.objs\include\doublefann.o(.text+0x2adc):doublefann.c: first defined here
.objs\include\fann.o(.text+0x176):fann.c: multiple definition of `fann_create_sparse_array'
.objs\include\doublefann.o(.text+0x176):doublefann.c: first defined here
.objs\include\fann.o(.text+0xa6):fann.c: multiple definition of `fann_create_standard_array'
.objs\include\doublefann.o(.text+0xa6):doublefann.c: first defined here
.objs\include\fann_cascade.o(.text+0x0):fann_cascade.c: multiple definition of `fann_print_connections_raw'
.objs\include\doublefann.o(.text+0x8a59):doublefann.c: first defined here
.objs\include\fann_cascade.o(.text+0x6a):fann_cascade.c: multiple definition of `fann_cascadetrain_on_data'
.objs\include\doublefann.o(.text+0x8ac3):doublefann.c: first defined here
.objs\include\fann_cascade.o(.text+0x2a9):fann_cascade.c: multiple definition of `fann_cascadetrain_on_file'
.objs\include\doublefann.o(.text+0x8d02):doublefann.c: first defined here
.objs\include\fann_cascade.o(.text+0x54b):fann_cascade.c: multiple definition of `fann_reallocate_connections'
.objs\include\doublefann.o(.text+0x8fa4):doublefann.c: first defined here
.objs\include\fann_cascade.o(.text+0x6e1):fann_cascade.c: multiple definition of `fann_reallocate_neurons'
.objs\include\doublefann.o(.text+0x913a):doublefann.c: first defined here
Process terminated with status 1 (0 minutes, 6 seconds)
52 errors, 0 warnings
The same project made for static library I've builded successfully. I was the same problems with other libraries.