Some fixes for building synApps on a fresh Ubuntu 22 successfully#6
Some fixes for building synApps on a fresh Ubuntu 22 successfully#6ibressler wants to merge 12 commits intoEPICS-synApps:mainfrom
Conversation
- no need to run the whole build script as root
The Makefile in GalilSup/src has this line:
That builds libGalilSupport.a and libGalilSupport.so in the top-level lib/linux-x86_64 directory. I just pulled and built synApps on an Ubuntu 22 system using the script and galil and xxx both built and were linked fine.
|
| system("./configure --prefix=${PWD}"); | ||
| system("make"); | ||
| `make install || true`; | ||
| `sudo make install || true`; |
There was a problem hiding this comment.
What is requiring root access here? The point of line 585 is that 'make install' will install everything into its own directory. I just ran the script on Ubuntu 22 and there were no root requirements.
There was a problem hiding this comment.
When running this in a fresh system with a regular unprivileged user, it tries to install udev rules and modifying ld.so.cache.
Here, this first example is from the Github Action runner:
make[1]: Leaving directory '/home/runner/work/EPICS-synApps-assemble/EPICS-synApps-assemble/synapps/support/measComp-R4-2/libuldaq-1.2.1'
/usr/bin/install: cannot create regular file '/lib/udev/rules.d/50-uldaq.rules': Permission denied
make[2]: *** [Makefile:484: install-dist_rulesdataDATA] Error 1
make[1]: *** [Makefile:814: install-am] Error 2
make: *** [Makefile:511: install-recursive] Error 1
This happens after the permissions to udev are fixed:
make[2]: Leaving directory '/epics/synapps/support/measComp-R4-2/libuldaq-1.2.1/examples'
make[2]: Entering directory '/epics/synapps/support/measComp-R4-2/libuldaq-1.2.1'
make[2]: Leaving directory '/epics/synapps/support/measComp-R4-2/libuldaq-1.2.1'
make[1]: Leaving directory '/epics/synapps/support/measComp-R4-2/libuldaq-1.2.1'
Failed to send reload request: Permission denied
/sbin/ldconfig.real: Can't create temporary cache file /etc/ld.so.cache~: Permission denied
make[3]: *** [Makefile:951: install-data-hook] Error 1
make[2]: *** [Makefile:866: install-data-am] Error 2
make[1]: *** [Makefile:814: install-am] Error 2
make: *** [Makefile:511: install-recursive] Error 1
To be sure, I removed sudo in my main branch and let it build as Github Action, the logs should be accessible for this job: https://github.com/BAMresearch/EPICS-synApps-assemble/actions/runs/8023437425/job/21919899065
There was a problem hiding this comment.
Edit: The build logs and artifacts are listed at the bottom of the summary of a build job, here: https://github.com/BAMresearch/EPICS-synApps-assemble/actions/runs/8023437425
assemble_synApps
Outdated
| $modules{'DEVIOCSTATS'} = '3.1.16'; | ||
| $modules{'ETHERIP'} = 'ether_ip-3-3'; | ||
| $modules{'GALIL'} = 'V3-5'; | ||
| $modules{'GALIL'} = 'V3-6'; |
There was a problem hiding this comment.
Galil V3-6 does not build on Windows machines, which is why 3-5 is the default. Individual modules can be adjusted for your specifications by using the --set flag.
There was a problem hiding this comment.
Thanks for pointing that out. I am fine with the option, of course.
There was a problem hiding this comment.
The Galil driver V3-6 and R3-6-85 have been patched to fix the build issue on Windows. The Galil repository name has changed recently and tag R3-6-85 was created to align the Galil repo structure to other synApps modules. I cloned this assemble_synApps repo and altered the assemble_synApps script for the Galil repo changes (see attached). After the assemble_synApps script completed successfully, I built the software by running "make" in the support folder. The software built successfully on CentOS stream 9, Windows 10 using visual studio 2019 & 2022.
assemble_synApps.txt
If the Galil driver isn't required, it can be commented out in configure/RELEASE.
There was a problem hiding this comment.
Thanks a lot for the update on that!
This does not seem to build here. In the Github Action I let it find all files in the Galil-* tree afterwards The missing files might be caused by my changes in this PR, especially 987cd35. a) Without my changes,
|
- since Windows compat. is fixed by now: EPICS-synApps#6 (comment)
|
|
Hi Keenan and Ingo, |
- due to updated motorapp/Galil repo, EPICS-synApps#6 (comment)
- due to updated motorapp/Galil repo, EPICS-synApps#6 (comment)
|
Thanks @motorapp! Works for me as well :) I added your changes to this pull request. They build fine in my main branch. Thanks a lot for the adjustments and testing! |
No rule to make target '../../../lib/linux-x86_64/libGalilSupport.a', needed by 'xxx'.(but I can't find any rule, reference or existence of a libGalilSupport in the Galil module while it builds without errors)sudo apt-get install -y git build-essential curl libusb-dev libusb-1.0-0-dev re2c x11proto-dev libx11-dev libxext-dev