Tango 9.2 fresh install on Ubuntu 16.04

Maybe the best is to create a new thread for this last question.

(maybe some one already created a package for hdb++).

Cheers
Hi Remotie,
hdb++ for TANGO 9 has to be built from source as per today. You can download the current source code from github:
https://github.com/tango-controls?utf8=%E2%9C%93&q=hdb&type=&language=c%2B%2B
and then follow the steps in the attached guide (except for the download… of course).
The guide is not very fresh, so maybe some bits… you'll have to cope with.
Cheers
Hi Lorenzo.
thanks for the link. i will follow it. But for instance i can not compile any C++ DS.
for example when trying to compile ModBus DS i've got these errors:
remotie@tangob:~/dservers/Modbus/src$ make
Compiling Modbus.cpp …
g++ -g -D_DEBUG -D_REENTRANT -W -I . -I../include -I. -I/usr/include/tango -I/usr/include -I/usr/local/include -DNOSERIAL -std=c++0x -Dlinux -c Modbus.cpp -o obj/Modbus.o
Modbus.cpp:43:19: fatal error: tango.h: Aucun fichier ou dossier de ce type
#include <tango.h>
^
compilation terminated.
/usr/share/pogo/preferences/common_target.opt:10 : la recette pour la cible « obj/Modbus.o » a échouée
make: *** [obj/Modbus.o] Erreur 1
remotie@tangob:~/dservers/Modbus/src$


I suppose that after fresh install of Tango, tango.h and others include files are not installed.

Regards
Hi,

I installed Tango 9.2.5a from the source package on an Ubuntu 16.04 LTS. By default it seems tango.h is installed under /usr/local/include/tango/.
If you installed Tango from the Source package, and if you used - -prefix option, it might have been installed elsewhere in your case… But in this case, Pogo should be aware of it.

What I would suggest is to re-generate the Makefile (using Pogo) for the device servers you need to compile.
The Makefiles coming with the device servers source code are not necessary in sync with your current installation.
Usually, simply re-generating the Makefile with Pogo and recompiling is enough… In some cases, you might need to adapt it a bit in order to specify additional options (special LFLAGS or CFLAGS options for instance).
Comparing the new Makefile and the old one might help to spot these special options.

Kind regards,
Reynald
Rosenberg's Law: Software is easy to make, except when you want it to do something new.
Corollary: The only software that's worth making is software that does something new.
Hi Reynald,
i regenerate the makefile using POGO, and i have the same error while compiling.
for information, i have Ubuntu 17.04

Regards.
Hi,
Now after installing libtango9 package. i can find the tango.h
but after compiling i've got the same issue with Serial.h. I try to fix it by adding the /usr/include/linux to the include_DIR but still having the same issue. After checking in /usr/include/linux the file exists but under serial.h (with small s instead of capital S). i replace #include <Serial.h> by #include <serial.h> in the DS c++ and i've got lot of errors (see the attachments)
Hi,

Do you need to use the Modbus protocol via a serial line in your case?
If yes, then you will need to download and install the Serial Tango device server. (serial.h file you found is not the expected one).
If not (which is probably your case), you should just add

CXXFLAGS_USR+= -DNOSERIAL

to your Makefile.
When looking at the compilation command line you posted before, it seems like the original Makefile was already using this -DNOSERIAL option.

I hope this helps,
Reynald
Rosenberg's Law: Software is easy to make, except when you want it to do something new.
Corollary: The only software that's worth making is software that does something new.
Thank Reynald,
i add -DNOSERIAL option to the makefile, it works not at 100%, the compilation ends with warning, though the bin was generated. i hope that is not so bad
there are the warnings:

Compiling ModbusCore.cpp …
g++ -g -D_DEBUG -D_REENTRANT -W -I . -I../include -I. -I/usr/include/tango -I/usr/include -I/usr/local/include -DNOSERIAL -std=c++0x -Dlinux -c ModbusCore.cpp -o obj/ModbusCore.o
ModbusCore.cpp: In member function ‘char* ModbusCore::GetErrorMessage(long int)’:
ModbusCore.cpp:1250:85: warning: format ‘%d’ expects argument of type ‘int’, but argument 3 has type ‘__time_t {aka long int}’ [-Wformat=]
f(&(ret_str[strlen(ret_str)]),"%d.%d s)",ip_timeout.tv_sec,ip_timeout.tv_usec);
^
ModbusCore.cpp:1250:85: warning: format ‘%d’ expects argument of type ‘int’, but argument 4 has type ‘__suseconds_t {aka long int}’ [-Wformat=]
Compiling ModbusCoreSL.cpp …
g++ -g -D_DEBUG -D_REENTRANT -W -I . -I../include -I. -I/usr/include/tango -I/usr/
Hi,
Very good…
Replacing %d with %ld in the printf should fix these warnings.

I don't know where you got your Modbus device server but it looks like you didn't get the latest version, which should not have this kind of warning…
According to the TANGO device classes catalog, you can get the latest version from tango-ds subversion repository:
http://svn.code.sf.net/p/tango-ds/code/DeviceClasses/Communication/Modbus

Have fun! smile
Rosenberg's Law: Software is easy to make, except when you want it to do something new.
Corollary: The only software that's worth making is software that does something new.
Hi Reynald;
the DS works fine with though the warning compilation.
now the next step is to install HDB++. i will update the dedicated thread with the steps

thank you very match
 
Register or login to create to post a reply.