pcl
pcl copied to clipboard
Windows all-in-one installer only does a partial install when used in silent mode.
Describe the bug
Windows all-in-one installer only does a partial install when used in silent mode.
Context
I am running allinoneinstaller.exe /S /D=C:/where/I/want/pcl
in a CI/CD (GitHub actions, but should not matter).
Expected behavior
I expect everything to be installed, including third-party packages, cmake files, etc. Just as would happen if I run the allinone installer interactively.
Current Behavior
Only bin
, lib
and include
are installed.
To Reproduce
Download the all-in-one installer and run with the command line above. May need to be done in an Administrator cmd/pwsh/bash.
Additional context
Maybe there are command-line switches I should pass to the NSIS installer, to make it select all options? But if there are it seems they are not documented anywhere. I found the /S
and /D
options on the nullsoft website, but if there are pcl-specific options needed for a full install I have not been able to find them.
I have also tried using the vcpkg
installer to install libpcl into the CI/CD, but that fails with one of the dependencies (I think boost), in addition to taking literally hours of runtime.
All components will be installed using PCL-1.12.1-AllInOne-msvc2019-win64.exe /S
.
It may require administrative privileges. Also, make sure there is enough free space in the storage you are trying to install. (Reference https://github.com/PointCloudLibrary/pcl/issues/5193#issuecomment-1055556556)
And, OpenNI2 is a separate installer and cannot be installed to a specific destination using PCL All-in-one Installer. It is always installed to the default installation destination. If you want to install OpenNI2 to other place, Please install OpenNI2 with a separate stand-alone installer.
Hmm, could be the disk space issue (I have no idea how much space GitHub Action runners have on their C:
drive). I will experiment and report back.
I've created a repo that shows the problem, https://github.com/jackjansen/pcl-install-test.
The repo is simply one of the PCL tests isolated, with its own CMakefile. It builds fine locally.
There's a single GitHub actions workflow, for Windows. It downloads the all-in-one installer and runs it, and then tries to build the project. (but before building it also shows the directory tree of what has actually been installed, in step See what is there
)
The GitHub action build log is at https://github.com/jackjansen/pcl-install-test/runs/6103367510?check_suite_focus=true
and it shows that only bin
, include
and lib
have been installed. None of the third party directories and other stuff....
If this is my error (which is probably likely:-) please let me know what I did wrong and how I should do this (and probably also document it so others don't make the same mistake)
It turns out that by just running the installer everything is indeed installed, eventually. It's just that the you don't know when the installer finishes running.
I have added a run to the repo above (tag working-with-sleep
) where everything installs fine, as long as I wait a (randomly determined) 120 seconds. Here is the log: https://github.com/jackjansen/pcl-install-test/runs/6166104944?check_suite_focus=true
But if I use Start-Process -Wait
the installer never finishes. Tag not-working-with-start-process-wait
, job log https://github.com/jackjansen/pcl-install-test/runs/6172607979?check_suite_focus=true
And I have also tried to run synchronously using .NET Process
, which also never finishes. Tag not-working-with-dotnet-process
, job log https://github.com/jackjansen/pcl-install-test/runs/6172724998?check_suite_focus=true
Finally I have tried the Start-Process -Wait
method on a local win10 machine, while logged in over SSH so I would not have access to the display (in case some UAC dialog or something was causing the problem). This worked fine.
I suspect there is some strange interaction between the PCL installer and the Github windows-latest
runner machines.
This feels to me like "the installer never finishes" in silent mode might be the actual issue (I'm using the 1.12.0 x64 version of the installer).
@jackjansen I'm experiencing the same situation on an Azure DevOps Pipeline. I'm going to check if your tagged working-with-sleep
works for me as well as a work around. Do you have any update on this, though?
@UnaNancyOwen Do you (or any other owner/contributor) happen to know if using the PCL Windows 'all in one' installer in Silent Mode on a CI pipeline was ever intended to be supported? If not, is it because of any well-known limitations or because there's another way to compile Windows applications depending on the PCL on a CI pipeline?
No, this installer was created to set up a development environment in general, it is not intended for CI pipelines. If you want to create a special installer for your purpose, you may be able to do it yourself. But, I can't support it. Sorry.
@germancoines the trick with starting the installer and then waiting works, but I have had to increase the sleep period a couple of times. It's now at 5 minutes, which hasn't failed yet:-)
See https://github.com/cwi-dis/cwipc/blob/master/.github/workflows/build.yml
It would be nicer to have a solution that checks whether all key components have been installed, but that's just too much work right now.