-
Notifications
You must be signed in to change notification settings - Fork 5
Compilation
####Build Instructions #####Compiling OFconnect library
$ make help
make objects : build library objects
make all : compile and link library
make install : install library
Needs root permissions
make clean : cleans all object files of library
make test : compile all tests
make runtest : execute all tests
Creates xml and html log files
make cleantest: cleans all temporary test files
including log files
If you want to run the compiled test programs multiple times, either manually invoke gtester for each program, or, run ‘make cleantest’ before every ‘make runtest’.
#####Compiling mul-OFconnect The makefiles of mul-OFconnect have been modified to include the libccof library.
./configure --with-glib=/usr/include/glib-2.0
make
sudo make install
#####Compiling a your_program.c file with OFconnect library
-
Compile and install the OFconnect library object make all make install
The paths to library directory and header file directory are hard-coded. Please modify Makefile to change each path if necessary.
Default location of libccof.so.0 - /usr/local/lib
Default location of cc_of_lib.h - /usr/local/include -
Include the header file in your code
#include “cc_of_lib.h” -
Follow instructions for compilation of glib applications: https://developer.gnome.org/glib/stable/glib-compiling.html Set an environment variable with necessary glib flags. For example:
GFLAGS='-I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -lglib-2.0'Note: the glib flags may vary on each system. Get the exact values from pkg-config output as instructed by Gnome’s manual for glib.
-
Finally, run GCC
gcc your_program.c $GFLAGS -lccof -I/usr/include/lib
|< < Prev Page|Next Page >>| |---------------------------|-------------------------------:|