next up previous contents 5
Next: Creating the mysql database Up: Installation Previous: Installing the mysql client   Contents


Installing DCSS

Each beam line must have one (and only one) installation of DCSS. The DCSS program must run on a computer that has network access to the computers that will be running the BLU-ICE clients as well as the computers running the Distributed Hardware Servers (DHS's). At SSRL, the DHS's usually run on computers that are on a private network, whereas the BLU-ICE's clients run on computers that are on a more open public network. This architecture implies that the DCSS program must run on a computer that is multi-homed and able to see both the public and private networks.

  1. Verify that you have a recent version of TCL installed on your computer.

    blctlxx:~/release-3_2 > tclsh
    % info tclversion
    8.3
    % exit
    blctlxx:~/release-3_2 >
    

  2. Install the mysql client libraries .

  3. Install the xos library .

  4. Install the auth library .

  5. Install the tcl_clibs .

  6. Install the dcs_tcl_packages library .

  7. Checkout the DCSS software into your DCS 'root' directory

    blctlxx:~/release-3_2 > cvs checkout -r release-3_2 dcss
    

  8. In 'src/dcss_users.c', there is a hardcoded reference to the 'smb' host database. Change this smb to the hostname of the machine running your mysql database.

    For example, if to change the database to local host you should expect the following diff results:

    blctlxx:~/release-3_2/dcss/src > cvs diff 
    cvs diff: Diffing .
    Index: dcss_users.c
    ===================================================================
    RCS file: /home/code/repository/dcss/src/dcss_users.c,v
    retrieving revision 1.8
    diff -r1.8 dcss_users.c
    94c94
    <   "smb","dcss",0,"beamline_configuration",0,0,0);
    ---
    >   "localhost","dcss",0,"beamline_configuration",0,0,0);
    blctlxx:~/release-3_2/dcss/src >
    

  9. If you are building DCSS on a non-linux computer, you may need to change the 'scripts/engine/scriptingEngine.tcl' file to reference the correct build directory for the tcl_clibs.so file.

    blctlxx:~/release-3_2/dcss/scripts/engine > grep tcl_clibs *
    scriptingEngine.tcl:load $DCS_DIR/tcl_clibs/linux/tcl_clibs.so dcs_c_library
    %$
    

  10. cd into the linux or decunix directory.

    blctlxx:~/release-3_2/ > cd dcss/linux/

  11. Build the software with the make command.

    blctlxx:~/release-3_2/dcss/linux > make
    cc -c -pthread -O5 -lsocket -DLINUX  -DSEC_BASE -DSEC_NET -Wall -I../src -I../../xos//src/ -I/usr/include -I../../auth/src -I/usr/include/mysql -I/usr/include/cxx ../src/dcss_main.c
    ../src/dcss_main.c: In function `start_server':
    ../src/dcss_main.c:205: warning: passing arg 2 of `xos_thread_create' from incompatible pointer type
    ../src/dcss_main.c:217: warning: passing arg 2 of `xos_thread_create' from incompatible pointer type
    ../src/dcss_main.c:228: warning: passing arg 2 of `xos_thread_create' from incompatible pointer type
    ../src/dcss_main.c: In function `restore_database':
    ../src/dcss_main.c:290: warning: int format, device_type_t arg (arg 3)
    ../src/dcss_main.c:323: warning: int format, circle_mode_t arg (arg 15)
    ../src/dcss_main.c:386: warning: int format, circle_mode_t arg (arg 9)
    cc: -lsocket: linker input file unused since linking not done
    cc -c -pthread -O5 -lsocket -DLINUX  -DSEC_BASE -DSEC_NET -Wall -I../src -I../../xos//src/ -I/usr/include -I../../auth/src -I/usr/include/mysql -I/usr/include/cxx ../src/dcss_database.c
    cc: -lsocket: linker input file unused since linking not done
    cc -c -pthread -O5 -lsocket -DLINUX  -DSEC_BASE -DSEC_NET -Wall -I../src -I../../xos//src/ -I/usr/include -I../../auth/src -I/usr/include/mysql -I/usr/include/cxx ../src/dcss_client.c
    cc: -lsocket: linker input file unused since linking not done
    cc -c -pthread -O5 -lsocket -DLINUX  -DSEC_BASE -DSEC_NET -Wall -I../src -I../../xos//src/ -I/usr/include -I../../auth/src -I/usr/include/mysql -I/usr/include/cxx ../src/dcss_scripting.c
    ../src/dcss_scripting.c: In function `scripting_thread':
    ../src/dcss_scripting.c:50: warning: implicit declaration of function `Itcl_Init'
    cc: -lsocket: linker input file unused since linking not done
    cc -c -pthread -O5 -lsocket -DLINUX  -DSEC_BASE -DSEC_NET -Wall -I../src -I../../xos//src/ -I/usr/include -I../../auth/src -I/usr/include/mysql -I/usr/include/cxx ../src/dcss_broadcast.c
    cc: -lsocket: linker input file unused since linking not done
    cc -c -pthread -O5 -lsocket -DLINUX  -DSEC_BASE -DSEC_NET -Wall -I../src -I../../xos//src/ -I/usr/include -I../../auth/src -I/usr/include/mysql -I/usr/include/cxx ../src/dcss_gui_client.c
    ../src/dcss_gui_client.c: In function `gtos_start_motor_move':
    ../src/dcss_gui_client.c:1101: warning: unused variable `correction'
    ../src/dcss_gui_client.c: In function `gtos_start_oscillation':
    ../src/dcss_gui_client.c:1293: warning: unused variable `correction'
    ../src/dcss_gui_client.c: In function `gtos_start_vector_move':
    ../src/dcss_gui_client.c:1335: warning: unused variable `device_2'
    ../src/dcss_gui_client.c:1333: warning: `deviceNum_2' might be used uninitialized in this function
    ../src/dcss_gui_client.c:1338: warning: `device2isNull' might be used uninitialized in this function
    ../src/dcss_gui_client.c: In function `gtos_stop_vector_move':
    ../src/dcss_gui_client.c:1414: warning: unused variable `device_2'
    ../src/dcss_gui_client.c: In function `gtos_change_vector_speed':
    ../src/dcss_gui_client.c:1479: warning: unused variable `device_2'
    cc: -lsocket: linker input file unused since linking not done
    cc -c -pthread -O5 -lsocket -DLINUX  -DSEC_BASE -DSEC_NET -Wall -I../src -I../../xos//src/ -I/usr/include -I../../auth/src -I/usr/include/mysql -I/usr/include/cxx ../src/dcss_hardware_client.c
    ../src/dcss_hardware_client.c: In function `write_to_hardware':
    ../src/dcss_hardware_client.c:862: warning: `result' might be used uninitialized in this function
    cc: -lsocket: linker input file unused since linking not done
    cc -c -pthread -O5 -lsocket -DLINUX  -DSEC_BASE -DSEC_NET -Wall -I../src -I../../xos//src/ -I/usr/include -I../../auth/src -I/usr/include/mysql -I/usr/include/cxx ../src/dcss_users.c
    cc: -lsocket: linker input file unused since linking not done
    cc -o dcss -lz dcss_main.o dcss_database.o dcss_client.o dcss_scripting.o dcss_broadcast.o dcss_gui_client.o dcss_hardware_client.o dcss_users.o -lm -lrt /usr/lib/mysql/libmysqlclient.a ../../xos//linux//xos.a ../../auth/linux/auth.a -lpthread -lc -ltk -ltcl -litcl
    


next up previous contents 5
Next: Creating the mysql database Up: Installation Previous: Installing the mysql client   Contents
Scott McPhillips 2003-03-11