get-cmake
get-cmake copied to clipboard
libidn11 not found
Thx for this action !
In some ubuntu runner I had the error with libidn11 not found (cmake3.3 and cmake 3.5). A hacky fix is to do :
sudo apt-get update ; sudo apt-get install --no-install-recommends -y libidn12; sudo ln -s /usr/lib/x86_64-linux-gnu/libidn.so.12 /usr/lib/x86_64-linux-gnu/libidn.so.11
Maybe this could be done one this action directly
@flagarde thank you for the suggestion! Glad to get a PR from the community for this improvement.
@lukka I would like to do a PR but I'm really not an expert on javascript. This is workaroud trick I have done :
async function fixes()
{
if(process.platform === "linux")
{
let cout ='';
let cerr='';
const options = {};
options.listeners = {
stdout: (data) => {
cout = data.toString();
},
stderr: (data) => {
cerr = data.toString();
}
}
options.silent = true
await exec.exec('sudo apt-get update', [], options)
await exec.exec('sudo apt-get install --no-install-recommends -y libidn12', [], options)
await exec.exec('sudo ln -sf /usr/lib/x86_64-linux-gnu/libidn.so.12 /usr/lib/x86_64-linux-gnu/libidn.so.11', [], options)
}
}
In you case you can download and make the change only if cmake is <=3.5 as this appears only for some version from 3.0 to 3.5.
I have found an other tricky problem related to SSL and dowload with file(DOWNLOAD) function for old CMake who are no related to this problem
@flagarde for this niche scenario, the best option is to just add documentation about how to install the required dependencies for cmake v3.5 and older version (i.e. just a run: step executing the commands, different for each Linux distro, to install the dependencies).
@flagarde closing this stale issue, contributions are always welcome though.