Dear All,
I am trying to implement a Tango Control System on a an experiment behind a High Power Laser Chain. The main purpose is to centralize all the diagnostic elements in one terminal and to pilot them with only a Tango Based API, able to grab all the data in a file, possibly in RT mode. I am new as developer, beforehand I have been acquainted with Tango use on FERMI FEL. Up to now I do not mean to implement it on all the laser chain and at the interface laser chain - beamline experiment, just the experiment.
Someone of you maybe remember that I previously posted on troubles upon installation from binaries on Windows 10, giving the same preamble. Sorry for bothering.
Here I could like to install Tango on my MacOS X machine, which is faster and handy to use for me. I need, when it comes, a recipe for installing Tango step by step from source, through the UNIX shell of course. I am not an expert of UNIX and Linux, but I have been already using them for a while. I already installed all the prerequisites (omniORB, zmq, doxygen, MariaDB) and checked the gcc and the Java RSE versions on the machine.
My major concerns are :
Do i have to put all the ./configure option (say --prefix=PREFIX, --enable-mariadb, and so on…) in the cmd line, or can I write a text file and call for it ?
Which environment variables do I have to put ? how and where ?
are “make” and “install” safe as is, or should I have change something in other files ?
Sorry for asking such a banal things, but I am starting almost from scratch.
your questions are valid. Let me try to answer them as best I can (I do not have a Mac):
1.Answer)If I understand your question you want to put the options in a file? You need to put the whole command in a file and run it as a script. I don’t think you can pass a file to the configure command. You could however use the shell to do this as follows:
./configure `cat myfileoptions`
[quote]2) Which environment variables do I have to put ? how and where ?
[/quote]
2.Answer) None a priori but you have to ensure the compilers and other commands needed are in your PATH. In the past I have set some environment variables like CFLAGS but this was to get around some tricky cases. I suggest you try without environment variables and let us know if you manage.
3.Answer) I think you need the autotools commands installed. You will need libtools.
Question to you: which version of the source code distribution of Tango are you installing?
If you are trying one of the recent (V9.3 and later) source code releases you will need cmake.
Maybe some MacOS users who have installed Tango can share their experience with you. I think FRMII uses BSD but I not sure this is on Mac hardware.
If you take the tar.gz file from the TangoSourceDistribution, you do not need CMake for the moment (even for latest 9.3.x-rc versions you can find as asset (tar.gz file) of the releases on the TangoSourceDistribution github repository). You only need CMake if you want to prepare the tar file.
What is your definition of safe in this context?
If you want to install to a predefined location, please use configure with the –prefix option.
By default, if –prefix is not specified, make install will try to install files in some standard Linux system locations where only root or sudoers will have permissions.
Thank you very much for your answers. I somewhat progressed in my understanding of the Configure process. Beforehand there were some troubles with the user definition of the MariaDB server and with Java. Still when I process "./configure --enable-mariadb --with-mysql-admin=david --with-mysql-admin-passwd=xxxxxxx --with-java=/usr/bin/java"i get a configuration like the one in the attached file (screenshot.png) and a long config.log , which is also attached. In view of the two reports, I understand that something is missing, but I do not understand what. At the moment I am stuck !!!
@Andy, @Reynald: Just a comment from the side lines. Do we have anyone using MacOSX as tango platform already? If not I would guess this will be a not-so-easy ride for getting it working.
I also have a mac running here with MacOSX Sierra so I can give that a shot as well.
[quote=“t-b”]@Andy, @Reynald: Just a comment from the side lines. Do we have anyone using MacOSX as tango platform already?
[/quote]
I don’t know.
There is a MacOS section on the forum but it’s not very active.
I had a quick look at the log file.
There is at least an issue with the detection of the version of java you’re using (11).
I think it would work if you would be using java 8.
This is something which has been fixed in the recent TangoSourceDistribution 9.3 release candidate versions.
9.2.5 release is starting to get old.
We have fixed as well the libmariadb version detection I think.
If we can make it work on Mac OS, this TangoSourceDistribution repository is the right location to report the encountered problems.
Maybe there is not much missing.
Downloaded and builded (it was mandatory) the cppzmq library, as it was needed the zmq.hpp include file
Downgraded to the Java 8 SE
run ./configure --enable-mariadb --with-mysql-admin=david --with-mysql-admin-passwd=xxxxxx --with-java=/usr/bin/java --disable-jpegmmx
The result is the Screenshot1_Tango_Configuration file, which is good and promising.
Then I run make all and still obtained some errors that I do not understand , which yo will find in Screenshot_Make_Issues. In particular I do not understand whether the compilation process looks for a “tango.h” and then lists a series of errors, but I do not know if they are fatal. In any case the make install command sort out no effect!!!
Nice to see some progress.
I think the problem you’re encountering is due to the differences between your MacOS X sed and the one provided with other linux distributions.
You can get a proper sed with brew install gnu-sed in case you are using homebrew. And then change in cppapi/server/idl/CMakeLists.txt in line 39 from sed to gsed.
The package generated by the TangoSourceDistribution repository does not use any CMakeLists.txt file.
It is still using the autoconf tools.
So I think, it’s more a Makefile.am file which should be modified.
Thanks a lot, I progressed. I downloaded gnu-sed via Homebrew and I just changed the paths file for pointing used. It seems that it worked. Now, always in the “make all” the files are compiled , but two errors are found during the compilation, in the device.cpp file and in another file from libraries. As usual, I attach the two concerned screenshots.
By the way, guys, if you think that this is a real useless effort, please tell me. I am trying to compile on MacOS X in order to use all my resources in terms of memory and processors, as I cannot afford a linux machine for the moment.
Anyway, thank you so much for your help.
@t-b : you were right, as far is the first instantiation erro concerned, I commented the wrong lines and the compilation passed without any trouble. But I do not know ho to manage the second error, because it is a line in a LLVM general library file which is called by included files (tango.h and devasyn.h. Do I have to comment the line calling for ? Or what else ?
Thanks a lot.
The compilation errors you’re facing could be related to the C++ standard your LLVM clang compiler is using.
I would try to force the standard to C++11 using the CXXFLAGS env. variable.
Just modify or create the CXXFLAGS :
export CXXFLAGS="$CXXFLAGS -std=c++11"
then retry to compile the code
make clean; make all
.
BTW, I would recommend to compile the whole software chain using the same options (including the C++11 standard).
I changed the CXXFLAGS as suggested , but still the error remains.
By the way, before I got other fatal error with jpegmmx.cpp, but in this case I disabled that part in during the ./configure process. Was I right ?
Still guys, I tried even to compile the same source on UBUNTU, but in this case I am stuck with OMNIORB4 installation from source, as there is some problems with python commands during the compilation due to several errors in idlpython.cpp. Do I have to create another thread ?
I suspect jpegmmx.cpp to make use of special CPU instructions and/or assembler routines. So it was a good idea to simply the compilation process by disabling the MMX functionalities.
Giving up on MacOS and switching to Linux is a good and reasonable idea
Concerning your OMNIORB4/Python problem. Is python or the the required python modules installed on your Ubuntu platform?
Could you please post the error details?