lete,t,r,n,i,o,a,s,l,u;functionc(e,t,r,n){Object.defineProperty(e,t,{get:r,set:n,enumerable:!0,configurable:!0});}functionp(e){returne&&e.__esModule?e.default:e;}functiond(e,t,r){if("function"==typeoft&&(r=t,t={}),!r){if("function"!=typeofPromise)throwTypeError("callback not provided");returnnewPromise(function(r,n){d(e,t||{},function(e,t){e?n(e):r(t);});});}rz(e,t||{},function(e,n){e&&("EACCES"===e.code||t&&t.ignoreErrors)&&(e=null,n=!1),r(e,n);});}functionf(e,t){letr;letn=e.options.env||process.env,i=process.cwd(),o=null!=e.options.cwd,a=o&&void0!==process.chdir&&!process.chdir.disabled;if(a)try{process.chdir(e.options.cwd);}catch(e){}try{r=rV.sync(e.command,{path:n[rY({env:n})],pathExt:t?ie.delimiter:void0});}catch(e){}finally{a&&process.chdir(i);}returnr&&(r=ie.resolve(o?e.options.cwd:"",r)),r;}functionh(e,t){returnObject.assign(Error(`${t}${e.command} ENOENT`),{code:"ENOENT",errno:"ENOENT",syscall:`${t}${e.command}`,path:e.command,spawnargs:e.args});}functionm(e,t){returni3&&1===e&&!t.file?h(t.original,"spawn"):null;}functiong(e,t,r){letn=rG(e,t,r),i=ru.spawn(n.command,n.args,n.options);returnr0.hookChildProcess(i,n),i;}functionv(e){lett="string"==typeofe?"\n":"\n".charCodeAt(),r="string"==typeofe?"\r":"\r".charCodeAt();returne[e.length-1]===t&&(e=e.slice(0,-1)),e[e.length-1]===r&&(e=e.slice(0,-1)),e;}functionE(e={}){let{env:t=process.env,platform:r=process.platform}=e;return"win32"!==r?"PATH":Object.keys(t).reverse().find(e=>"PATH"===e.toUpperCase())||"Path";}functionw({env:e=p(rm).env,...t}={}){letr=E({env:e={...e}});returnt.path=e[r],e[r]=function(e={}){lett;let{cwd:r=p(rm).cwd(),path:n=p(rm).env[E()],execPath:i=p(rm).execPath}=e,o=iinstanceofURL?p(rg).fileURLToPath(i):i,a=rinstanceofURL?p(rg).fileURLToPath(r):r,s=p(rf).resolve(a),l=[];for(;t!==s;)l.push(p(rf).join(s,"node_modules/.bin")),t=s,s=p(rf).resolve(s,"..");returnl.push(p(rf).resolve(a,o,"..")),[...l,n].join(p(rf).delimiter);}(t),e;}functiony(e){returnnull!==e&&"object"==typeofe&&"function"==typeofe.pipe;}functionb(e){returny(e)&&!1!==e.writable&&"function"==typeofe._write&&"object"==typeofe._writableState;}asyncfunctionx(e,t){if(!e)throwError("Expected a stream");let{maxBuffer:r}=t={maxBuffer:1/0,...t},n=r8(t);returnawaitnewPromise((t,i)=>{leto=e=>{e&&n.getBufferedLength()<=r5.MAX_LENGTH&&(e.bufferedData=n.getBufferedValue()),i(e);};(async()=>{try{awaitoV(e,n),t();}catch(e){o(e);}})(),n.on("data",()=>{n.getBufferedLength()>r&&o(newoX());});}),n.getBufferedValue();}functionD(e,t,r){letn;leti=ac(e,t,r),o=o9(e,t),a=o7(e,t);al(a,i.options),oj(i.options);try{n=p(rh).spawn(i.file,i.args,i.options);}catch(t){lete=new(p(rh).ChildProcess)();returno4(e,Promise.reject(of({error:t,stdout:"",stderr:"",all:"",command:o,escapedCommand:a,parsed:i,timedOut:!1,isCanceled:!1,killed:!1}))),e;}lets=o5(n),l=oM(n,i.options,s),u=oq(n,i.options,l),c={isCanceled:!1};n.kill=o_.bind(null,n.kill.bind(n)),n.cancel=oU.bind(null,n,c);letd=r1(async()=>{let[{error:e,exitCode:t,signal:r,timedOut:s},l,p,d]=awaito1(n,i.options,u),f=ap(i.options,l),h=ap(i.options,p),m=ap(i.options,d);if(e||0!==t||null!==r){letl=of({error:e,exitCode:t,signal:r,stdout:f,stderr:h,all:m,command:o,escapedCommand:a,parsed:i,timedOut:s,isCanceled:c.isCanceled||!!i.options.signal&&i.options.signal.aborted,killed:n.killed});if(!i.options.reject)returnl;throwl;}return{command:o,escapedCommand:a,exitCode:0,stdout:f,stderr:h,all:m,failed:!1,timedOut:!1,isCanceled:!1,killed:!1};});returnoQ(n,i.options),n.all=oJ(n,i.options),oH(n),o4(n,d),n;}functionS(e,t,r){letn;leti=ac(e,t,r),o=o9(e,t),a=o7(e,t);al(a,i.options);lets=oW(i.options);try{n=p(rh).spawnSync(i.file,i.args,{...i.options,input:s});}catch(e){throwof({error:e,stdout:"",stderr:"",all:"",command:o,escapedCommand:a,parsed:i,timedOut:!1,isCanceled:!1,killed:!1});}letl=ap(i.options,n.stdout,n.error),u=ap(i.options,n.stderr,n.error);if(n.error||0!==n.status||null!==n.signal){lete=of({stdout:l,stderr:u,error:n.error,signal:n.signal,exitCode:n.status,command:o,escapedCommand:a,parsed:i,timedOut:
`),(0,ny.info)(`${e}="${n}"wasaddedto"${so}`));return;}process.env[e]=n;}async function q(e){switch(process.platform){case"win32":await U(`$USER_PATH=([Environment]::GetEnvironmentVariable("PATH", "User")); [Environment]::SetEnvironmentVariable("PATH", "${e};$USER_PATH", "User")`),(0,ny.info)(`"${e}" was added to the PATH.`);return;case"linux":case"darwin":awaitB(),(0,it.appendFileSync)(so,`
`),(0,ny.info)(`"${e}"wasaddedto"${so}"`);return;default:return;}}async function B(){if(sa)return;let e="# Automatically Generated by setup-cpp\nexport SOURCE_CPPRC=0";if((await(0,nD.pathExists)(so))&&(0,it.readFileSync)(so,"utf8").includes(e))return;(0,it.appendFileSync)(so,`
`),console.table({"compiler and analyzer":{tools:"--llvm, --gcc, --msvc, --vcvarsall, --cppcheck, --clangtidy, --clangformat"},"build system":{tools:"--cmake, --ninja, --meson, --make, --task, --bazel"},"package manager":{tools:"--vcpkg, --conan, --choco, --brew, --nala"},cache:{tools:"--cppcache, --sccache"},documentation:{tools:"--doxygen, --graphviz"},coverage:{tools:"--gcovr, --opencppcoverage, --kcov"},other:{tools:"--python, --powershell, --sevenzip"}},["tools"]));let l=null!==(t=s.architecture)&&void 0!==t?t:process.arch,u=null!==(r=process.env.SETUP_CPP_DIR)&&void 0!==r?r:C("~"),c=[],d=[],f=rL.create({autoloadLocales:!0});rL.addLocale(p(r$)),rC.addLocale(p(r_));let h=await sF();if(!function(e,t){let r=t.filter(t=>void 0!==e[t]),n=r.filter(t=>!e2(e[t])),i=n.length>=1?e[n[0]]:"true";return!n.some(t=>e[t]!==i)&&(r.forEach(t=>{e[t]=i;}),!0);}(s,["llvm","clangtidy","clangformat"]))return(0,rO.error)("The same version must be used for llvm, clangformat and clangtidy"),1;ea()&&"string"==typeof s.cppcheck&&"string"==typeof s.gcovr&&((0,rO.info)("installing python-pygments to avoid conflicts with cppcheck and gcovr on Arch linux"),await ed("python-pygments"));let m=!1,g=!1;for(let e of lk){if(rR.isCI&&0!==d.length){g=!0;break;}let t=s[e];void 0!==t&&(i=Date.now(),m=await tU(e,t,h,l,u,c,d,6e4*parseFloat(null!==(n=s.timeout)&&void 0!==n?n:"20")),o=Date.now(),(0,rO.info)("took "+(f.format(i,o)||"0 seconds")));}if(!g){let e=s.compiler;if(void 0!==e){let t=Date.now();await re(e,h,u,l,c,m,d);let r=Date.now();(0,rO.info)("took "+(f.format(t,r)||"0 seconds"));}}if(await G(),0===c.length&&0===d.length)return(0,rO.warning)("setup-cpp was called without any arguments. Nothing to do."),0;if(c.forEach(e=>(0,rO.success)(e)),d.forEach(e=>(0,rO.error)(e)),(0,rO.info)("setup-cpp finished"),!rR.GITHUB_ACTIONS)switch(process.platform){case"win32":(0,rO.warning)("Run `RefreshEnv.cmd` or restart your shell to update the environment.");break;case"linux":case"darwin":(0,rO.warning)("Run `source~/.cpprc`orrestartyourshelltoupdatetheenvironment.");}returnawaita,0===d.length?0:1;}varrr,rn,ri,ro,ra,rs,rl,ru,rc,rp,rd,rf,rh,rm,rg,rv,rE,rw,ry,rb,rx,rD,rS,rT,rN,rI,rA,rR,rO,rC,r_,rL,r$,rP,rk,rU,rF,rM,rj,rq,rB,rG,rH,rV,rX,rz,rY,rW,rK,rQ,rJ,rZ,r0,r1,r3,r2,r4,r5,r6,r8,r9,r7,ne,nt,nr,nn,ni,no,na,ns,nl,nu,nc,np,nd,nf,nh,nm,ng,nv,nE,nw,ny,nb,nx,nD,nS,nT,nN,nI,nA,nR,nO,nC,n_,nL,n$,nP,nk,nU,nF,nM,nj,nq,nB,nG,nH,nV,nX,nz,nY,nW,nK,nQ,nJ,nZ,n0,n1,n3,n2,n4,n5,n6,n8,n9,n7=require("os"),ie=require("path"),it=require("fs"),ir=require("crypto"),ii=require("http"),io=require("https");require("net"),ri=require("tls"),ro=require("events"),ra=require("assert"),rs=require("util"),rl=require("fs"),ru=require("child_process"),rc=require("string_decoder"),rp=require("timers"),rd=require("buffer"),rf=require("path"),rh=require("child_process"),rm=require("process"),rg=require("url"),rv=require("os"),rE=require("buffer"),rw=require("stream"),ry=require("util"),rb=require("process"),rx=require("url"),rD=require("console"),rT={},rN={},null==(rI=(rS=globalThis).parcelRequire810d)&&((rI=function(e){if(einrT)returnrT[e].exports;if(einrN){vart=rN[e];deleterN[e];varr={id:e,exports:{}};returnrT[e]=r,t.call(r.exports,r,r.exports),r.exports;}varn=Error("Cannotfindmodule'"+e+"'");thrown.code="MODULE_NOT_FOUND",n;}).register=function(e,t){rN[e]=t;},rS.parcelRequire810d=rI),(rA=rI.register)("dAuy6",function(e,t){varr;functionn(e){return"string"==typeofe?!!i[e]:"env"ine?i[e.env]&&i[e.env].includes(e.includes):"any"ine?e.any.some(function(e){return!!i[e];}):Object.keys(e).every(function(t){returni[t]===e[t];});}r=rI("5vZJI");leti=process.env;Object.defineProperty(e.exports,"_vendors",{value:r.map(function(e){returne.constant;})}),e.exports.name=null,e.exports.isPR=null,r.forEach(function(t){letr=(Array.isArray(t.env)?t.env:[t.env]).every(function(e){returnn(e);});if(e.exports[t.constant]=r,r)switch(e.exports.name=t.name,typeoft.pr){case"string":e.exports.isPR=!!i[t.pr];break;case"object":"env"int.pr?e.exports.isPR=t.pr.envini&&i[t.pr.env]!==t.pr.ne:"any
ErrorMessage:${e.message}`);})).result)||void 0===t?void 0:t.value;if(!n)throw Error("Response json body do not have ID Token field");return n;});}static getIDToken(e){return r(this,void 0,void 0,function*(){try{let t=a.getIDTokenUrl();if(e){let r=encodeURIComponent(e);t=`${t}&audience=${r}`;}o.debug("ID token url is "+t);let r=yield a.getCall(t);return o.setSecret(r),r;}catch(e){throw Error("Error message: "+e.message);}});}}e.exports.OidcClient=a;}),rA("eamjo",function(e,t){var r,n,i,o,a,s,l,u,c;r=e.exports&&e.exports.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r];}});}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r];}),n=e.exports&&e.exports.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t});}:function(e,t){e.default=t;}),i=e.exports&&e.exports.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var i in e)"default"!==i&&Object.hasOwnProperty.call(e,i)&&r(t,e,i);return n(t,e),t;},o=e.exports&&e.exports.__awaiter||function(e,t,r,n){return new(r||(r=Promise))(function(i,o){function a(e){try{l(n.next(e));}catch(e){o(e);}}function s(e){try{l(n.throw(e));}catch(e){o(e);}}function l(e){var t;e.done?i(e.value):((t=e.value)instanceof r?t:new r(function(e){e(t);})).then(a,s);}l((n=n.apply(e,t||[])).next());});},Object.defineProperty(e.exports,"__esModule",{value:!0}),e.exports.HttpClient=e.exports.isHttps=e.exports.HttpClientResponse=e.exports.HttpClientError=e.exports.getProxyUrl=e.exports.MediaTypes=e.exports.Headers=e.exports.HttpCodes=void 0;let p=i(ii),d=i(io),f=i(rI("jnrYh")),h=i(rI("3RDK7"));(u=a=e.exports.HttpCodes||(e.exports.HttpCodes={}))[u.OK=200]="OK",u[u.MultipleChoices=300]="MultipleChoices",u[u.MovedPermanently=301]="MovedPermanently",u[u.ResourceMoved=302]="ResourceMoved",u[u.SeeOther=303]="SeeOther",u[u.NotModified=304]="NotModified",u[u.UseProxy=305]="UseProxy",u[u.SwitchProxy=306]="SwitchProxy",u[u.TemporaryRedirect=307]="TemporaryRedirect",u[u.PermanentRedirect=308]="PermanentRedirect",u[u.BadRequest=400]="BadRequest",u[u.Unauthorized=401]="Unauthorized",u[u.PaymentRequired=402]="PaymentRequired",u[u.Forbidden=403]="Forbidden",u[u.NotFound=404]="NotFound",u[u.MethodNotAllowed=405]="MethodNotAllowed",u[u.NotAcceptable=406]="NotAcceptable",u[u.ProxyAuthenticationRequired=407]="ProxyAuthenticationRequired",u[u.RequestTimeout=408]="RequestTimeout",u[u.Conflict=409]="Conflict",u[u.Gone=410]="Gone",u[u.TooManyRequests=429]="TooManyRequests",u[u.InternalServerError=500]="InternalServerError",u[u.NotImplemented=501]="NotImplemented",u[u.BadGateway=502]="BadGateway",u[u.ServiceUnavailable=503]="ServiceUnavailable",u[u.GatewayTimeout=504]="GatewayTimeout",(c=s=e.exports.Headers||(e.exports.Headers={})).Accept="accept",c.ContentType="content-type",(l=e.exports.MediaTypes||(e.exports.MediaTypes={})).ApplicationJson="application/json",e.exports.getProxyUrl=function(e){let t=f.getProxyUrl(new URL(e));return t?t.href:"";};let m=[a.MovedPermanently,a.ResourceMoved,a.SeeOther,a.TemporaryRedirect,a.PermanentRedirect],g=[a.BadGateway,a.ServiceUnavailable,a.GatewayTimeout],v=["OPTIONS","GET","DELETE","HEAD"];class E extends Error{constructor(e,t){super(e),this.name="HttpClientError",this.statusCode=t,Object.setPrototypeOf(this,E.prototype);}}e.exports.HttpClientError=E;class w{constructor(e){this.message=e;}readBody(){return o(this,void 0,void 0,function*(){return new Promise(e=>o(this,void 0,void 0,function*(){let t=Buffer.alloc(0);this.message.on("data",e=>{t=Buffer.concat([t,e]);}),this.message.on("end",()=>{e(t.toString());});}));});}}e.exports.HttpClientResponse=w,e.exports.isHttps=function(e){return"https:"===new URL(e).protocol;},e.exports.HttpClient=class{constructor(e,t,r){this._ignoreSslError=!1,this._allowRedirects=!0,this._allowRedirectDowngrade=!1,this._maxRedirects=50,this._allowRetries=!1,this._maxRetries=1,this._keepAlive=!1,this._disposed=!1,this.userAgent=e,this.handlers=t||[],this.requestOptions=r,r&&(null!=r.ignoreSslError&&(thi
${t}`,i8=Object.getOwnPropertyDescriptor(Function.prototype,"toString"),i9=Object.getOwnPropertyDescriptor(Function.prototype.toString,"name"),i7=(e,t,r)=>{let n=""===r?"":`with${r.trim()}()`,i=i6.bind(null,n,t.toString());Object.defineProperty(i,"name",i9),Object.defineProperty(e,"toString",{...i8,value:i});},oe=new WeakMap(),ot=(e,t={})=>{let r;if("function"!=typeof e)throw TypeError("Expected a function");let n=0,i=e.displayName||e.name||"<anonymous>",o=function(...a){if(oe.set(o,++n),1===n)r=e.apply(this,a),e=null;else if(!0===t.throw)throw Error(`Function\`${i}\` can only be called once`);returnr;};return!function(e,t,{ignoreNonConfigurable:r=!1}={}){let{name:n}=e;for(letnofReflect.ownKeys(t))i2(e,t,n,r);i5(e,t),i7(e,t,n);}(o,e),oe.set(o,n),o;};ot.callCount=e=>{if(!oe.has(e))throwError(`The given function \`${e.name}\` is not wrapped by the \`onetime\` package`);returnoe.get(e);},r1=ot;constor=()=>Array.from({length:oo-oi+1},on),on=(e,t)=>({name:"SIGRT"+(t+1),number:oi+t,action:"terminate",description:"Application-specific signal (realtime)",standard:"posix"}),oi=34,oo=64,oa=[{name:"SIGHUP",number:1,action:"terminate",description:"Terminal closed",standard:"posix"},{name:"SIGINT",number:2,action:"terminate",description:"User interruption with CTRL-C",standard:"ansi"},{name:"SIGQUIT",number:3,action:"core",description:"User interruption with CTRL-\\",standard:"posix"},{name:"SIGILL",number:4,action:"core",description:"Invalid machine instruction",standard:"ansi"},{name:"SIGTRAP",number:5,action:"core",description:"Debugger breakpoint",standard:"posix"},{name:"SIGABRT",number:6,action:"core",description:"Aborted",standard:"ansi"},{name:"SIGIOT",number:6,action:"core",description:"Aborted",standard:"bsd"},{name:"SIGBUS",number:7,action:"core",description:"Bus error due to misaligned, non-existing address or paging error",standard:"bsd"},{name:"SIGEMT",number:7,action:"terminate",description:"Command should be emulated but is not implemented",standard:"other"},{name:"SIGFPE",number:8,action:"core",description:"Floating point arithmetic error",standard:"ansi"},{name:"SIGKILL",number:9,action:"terminate",description:"Forced termination",standard:"posix",forced:!0},{name:"SIGUSR1",number:10,action:"terminate",description:"Application-specific signal",standard:"posix"},{name:"SIGSEGV",number:11,action:"core",description:"Segmentation fault",standard:"ansi"},{name:"SIGUSR2",number:12,action:"terminate",description:"Application-specific signal",standard:"posix"},{name:"SIGPIPE",number:13,action:"terminate",description:"Broken pipe or socket",standard:"posix"},{name:"SIGALRM",number:14,action:"terminate",description:"Timeout or timer",standard:"posix"},{name:"SIGTERM",number:15,action:"terminate",description:"Termination",standard:"ansi"},{name:"SIGSTKFLT",number:16,action:"terminate",description:"Stack is empty or overflowed",standard:"other"},{name:"SIGCHLD",number:17,action:"ignore",description:"Child process terminated, paused or unpaused",standard:"posix"},{name:"SIGCLD",number:17,action:"ignore",description:"Child process terminated, paused or unpaused",standard:"other"},{name:"SIGCONT",number:18,action:"unpause",description:"Unpaused",standard:"posix",forced:!0},{name:"SIGSTOP",number:19,action:"pause",description:"Paused",standard:"posix",forced:!0},{name:"SIGTSTP",number:20,action:"pause",description:'Paused using CTRL-Z or "suspend"',standard:"posix"},{name:"SIGTTIN",number:21,action:"pause",description:"Background process cannot read terminal input",standard:"posix"},{name:"SIGBREAK",number:21,action:"terminate",description:"User interruption with CTRL-BREAK",standard:"other"},{name:"SIGTTOU",number:22,action:"pause",description:"Background process cannot write to terminal output",standard:"posix"},{name:"SIGURG",number:23,action:"ignore",description:"Socket received out-of-band data",standard:"bsd"},{name:"SIGXCPU",number:24,action:"core",description:"Process timed out",standard:"bsd"},{name:"SIGXFSZ",number:25,action:"core",description:"File too big",standard:"bsd"},{name:"SIGVTALRM",number:26,action:"t
${n.message}`:g,w=[E,t,e].filter(Boolean).join("\n");return v?(n.originalMessage=n.message,n.message=w):n=Error(w),n.shortMessage=E,n.command=a,n.escapedCommand=s,n.exitCode=o,n.signal=i,n.signalDescription=h,n.stdout=e,n.stderr=t,n.cwd=f,void 0!==r&&(n.all=r),"bufferedData"in n&&delete n.bufferedData,n.failed=!0,n.timedOut=!!l,n.isCanceled=u,n.killed=c&&!l,n;},oh=["stdin","stdout","stderr"],om=e=>oh.some(t=>void 0!==e[t]),og=e=>{if(!e)return;let{stdio:t}=e;if(void 0===t)return oh.map(t=>e[t]);if(om(e))throw Error("It's not possible to provide `stdio` in combination with one of "+oh.map(e=>`\`${e}\``).join(", "));if("string"==typeoft)returnt;if(!Array.isArray(t))throwTypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeoft}\``);returnArray.from({length:Math.max(t.length,oh.length)},(e,r)=>t[r]);};r3={};constov=function(e){returne&&"object"==typeofe&&"function"==typeofe.removeListener&&"function"==typeofe.emit&&"function"==typeofe.reallyExit&&"function"==typeofe.listeners&&"function"==typeofe.kill&&"number"==typeofe.pid&&"function"==typeofe.on;};if(ov(r2=rS.process)){varoE,ow=ra,oy=rI("dVIKq"),ob=/^win/i.test(r2.platform),ox=ro;"function"!=typeofox&&(ox=ox.EventEmitter),r2.__signal_exit_emitter__?oE=r2.__signal_exit_emitter__:((oE=r2.__signal_exit_emitter__=newox()).count=0,oE.emitted={}),oE.infinite||(oE.setMaxListeners(1/0),oE.infinite=!0);varoD=function(){oN&&ov(rS.process)&&(oN=!1,oy.forEach(function(e){try{r2.removeListener(e,oT[e]);}catch(e){}}),r2.emit=oO,r2.reallyExit=oA,oE.count-=1);};(r3=function(e,t){if(!ov(rS.process))returnfunction(){};ow.equal(typeofe,"function","a callback must be provided for exit handler"),!1===oN&&oI();varr="exit";returnt&&t.alwaysLast&&(r="afterexit"),oE.on(r,e),function(){oE.removeListener(r,e),0===oE.listeners("exit").length&&0===oE.listeners("afterexit").length&&oD();};}).unload=oD;varoS=function(e,t,r){oE.emitted[e]||(oE.emitted[e]=!0,oE.emit(e,t,r));},oT={};oy.forEach(function(e){oT[e]=function(){ov(rS.process)&&r2.listeners(e).length===oE.count&&(oD(),oS("exit",null,e),oS("afterexit",null,e),ob&&"SIGHUP"===e&&(e="SIGINT"),r2.kill(r2.pid,e));};}),r3.signals=function(){returnoy;};varoN=!1,oI=function(){!oN&&ov(rS.process)&&(oN=!0,oE.count+=1,oy=oy.filter(function(e){try{returnr2.on(e,oT[e]),!0;}catch(e){return!1;}}),r2.emit=oC,r2.reallyExit=oR);};r3.load=oI;varoA=r2.reallyExit,oR=function(e){ov(rS.process)&&(r2.exitCode=e||0,oS("exit",r2.exitCode,null),oS("afterexit",r2.exitCode,null),oA.call(r2,r2.exitCode));},oO=r2.emit,oC=function(e,t){if(!("exit"===e&&ov(rS.process)))returnoO.apply(this,arguments);void0!==t&&(r2.exitCode=t);varr=oO.apply(this,arguments);returnoS("exit",r2.exitCode,null),oS("afterexit",r2.exitCode,null),r;};}elser3=function(){returnfunction(){};};consto_=(e,t="SIGTERM",r={})=>{letn=e(t);returnoL(e,t,r,n),n;},oL=(e,t,r,n)=>{if(!o$(t,r,n))return;leti=setTimeout(()=>{e("SIGKILL");},ok(r));i.unref&&i.unref();},o$=(e,{forceKillAfterTimeout:t},r)=>oP(e)&&!1!==t&&r,oP=e=>e===p(rv).constants.signals.SIGTERM||"string"==typeofe&&"SIGTERM"===e.toUpperCase(),ok=({forceKillAfterTimeout:e=!0})=>{if(!0===e)return5e3;if(!Number.isFinite(e)||e<0)throwTypeError(`Expected the \`forceKillAfterTimeout\` option to be a non-negative integer, got \`${e}\` (${typeofe})`);returne;},oU=(e,t)=>{e.kill()&&(t.isCanceled=!0);},oF=(e,t,r)=>{e.kill(t),r(Object.assign(Error("Timed out"),{timedOut:!0,signal:t}));},oM=(e,{timeout:t,killSignal:r="SIGTERM"},n)=>{leti;return0===t||void0===t?n:Promise.race([newPromise((n,o)=>{i=setTimeout(()=>{oF(e,r,o);},t);}),n.finally(()=>{clearTimeout(i);})]);},oj=({timeout:e})=>{if(void0!==e&&(!Number.isFinite(e)||e<0))throwTypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${e}\` (${typeofe})`);},oq=async(e,{cleanup:t,detached:r},n)=>{if(!t||r)returnn;leti=p(r3)(()=>{e.kill();});returnn.finally(()=>{i();});},oB=e=>einstanceofrh.ChildProcess&&"function"==typeofe.then,oG=(e,t,r)=>{if("string"==typeofr)returne[t].pipe((0,rl.createWriteStream)(r)),e;if(b
`);},au=({env:e,extendEnv:t,preferLocal:r,localDir:n,execPath:i})=>{let o=t?{...p(rm).env,...e}:e;return r?w({env:o,cwd:n,execPath:i}):o;},ac=(e,t,r={})=>{let n=p(rB)._parse(e,t,r);return e=n.command,t=n.args,(r={maxBuffer:1e8,buffer:!0,stripFinalNewline:!0,extendEnv:!0,preferLocal:!1,localDir:(r=n.options).cwd||p(rm).cwd(),execPath:p(rm).execPath,encoding:"utf8",reject:!0,cleanup:!0,all:!1,windowsHide:!0,verbose:ao,...r}).env=au(r),r.stdio=og(r),"win32"===p(rm).platform&&"cmd"===p(rf).basename(e,".exe")&&t.unshift("/q"),{file:e,args:t,options:r,parsed:n};},ap=(e,t,r)=>"string"==typeof t||(0,rd.Buffer).isBuffer(t)?e.stripFinalNewline?v(t):t:void 0===r?void 0:"",ad=({input:e,inputFile:t,stdio:r})=>void 0===e&&void 0===t&&void 0===r?{stdin:"inherit"}:{},af=(e={})=>({preferLocal:!0,...ad(e),...e});!function e(t){function r(n,...i){if(!Array.isArray(n))return e({...t,...n});let[o,...a]=ai(n,i);return D(o,a,af(t));}return r.sync=(e,...r)=>{if(!Array.isArray(e))throw TypeError("Please use $(options).sync`command` instead of $.sync(options)`command`.");let[n,...i]=ai(e,r);return S(n,i,af(t));},r;}();const ah={stdio:"inherit",shell:!0},am=/^~(?=$|\/|\\)/;rO=rI("hHq4F"),nt={},nr=rI("coVwk"),nn=rb.env.npm_package_json,no=!!((ni=rb.env.npm_config_user_agent)&&ni.startsWith("npm")),na=!!(nn&&nn.endsWith("package.json")),ns=no||na,nl=!!(ni&&ni.startsWith("yarn")),nu=ns||nl,nc=n7.homedir(),np=process.env.XDG_CONFIG_HOME||ie.join(nc,".config","simple-update-notifier"),nd=function(e){return ie.join(np,"".concat(e.replace("@","").replace("/","__"),".json"));},nf=function(){it.existsSync(np)||it.mkdirSync(np,{recursive:!0});},nh=function(e){var t=nd(e);try{if(!it.existsSync(t))return;return JSON.parse(it.readFileSync(t,"utf8")).lastUpdateCheck;}catch(e){return;}},nm=function(e){var t=nd(e);it.writeFileSync(t,JSON.stringify({lastUpdateCheck:new Date().getTime()}));},ng=function(e,t){return _(void 0,void 0,void 0,function(){var r;return L(this,function(n){return r="https://registry.npmjs.org/-/package/".concat(e,"/dist-tags"),[2,new Promise(function(e,n){io.get(r,function(r){var i="";r.on("data",function(e){return i+=e;}),r.on("end",function(){try{var r=JSON.parse(i)[t];r||n(Error("Error getting version")),e(r);}catch(e){n(Error("Could not parse version response"));}});}).on("error",function(e){return n(e);});})];});});},nv=function(e){var t=e.pkg,r=e.updateCheckInterval,n=void 0===r?864e5:r,i=e.distTag,o=void 0===i?"latest":i,a=e.alwaysRun,s=e.debug;return _(void 0,void 0,void 0,function(){var e,r;return L(this,function(i){switch(i.label){case 0:if(nf(),e=nh(t.name),!(a||!e||e<new Date().getTime()-n))return[3,2];return[4,ng(t.name,o)];case 1:if(r=i.sent(),nm(t.name),nr.gt(r,t.version))return[2,r];return s&&console.error("Latest version (".concat(r,") not newer than current version (").concat(t.version,")")),[3,3];case 2:s&&console.error("Too recent to check for a new update. simpleUpdateNotifier() interval set to ".concat(n,"ms but only ").concat(new Date().getTime()-e,"ms since last check.")),i.label=3;case 3:return[2,!1];}});});},nE=function(e){for(var t=e.split("\n"),r=Math.max.apply(Math,t.map(function(e){return e.length;})),n=["┌".concat("─".repeat(r+2),"┐")],i=0;i<t.length;i++){var o=t[i];n.push("│ ".concat(o.padEnd(r)," │"));}return n.push("└".concat("─".repeat(r+2),"┘")),n.join("\n");},nt=function(e){return _(void 0,void 0,void 0,function(){var t,r;return L(this,function(n){switch(n.label){case 0:if(!e.alwaysRun&&(!process.stdout.isTTY||nu&&!e.shouldNotifyInNpmScript))return e.debug&&console.error("Opting out of running simpleUpdateNotifier()"),[2];n.label=1;case 1:return n.trys.push([1,3,,4]),[4,nv(e)];case 2:return(t=n.sent())&&console.error(nE("New version of ".concat(e.pkg.name," available!\nCurrent Version: ").concat(e.pkg.version,"\nLatest Version: ").concat(t))),[3,4];case 3:return r=n.sent(),e.debug&&r instanceof Error&&console.error("Unexpected error in simpleUpdateNotifier():",r),[3,4];case 4:return[2];}});});},nw={},nw=JSON.parse('{"name":"setup-cpp","version":"0.36.2"}'),ny=rI("1o3Gj"),rO=rI("hHq4F"),rR
${n.message}`:h,v=[g,t,e].filter(Boolean).join("\n");return m?(n.originalMessage=n.message,n.message=v):n=Error(v),n.shortMessage=g,n.command=a,n.escapedCommand=s,n.exitCode=o,n.signal=i,n.signalDescription=d,n.stdout=e,n.stderr=t,void 0!==r&&(n.all=r),"bufferedData"in n&&delete n.bufferedData,n.failed=!0,n.timedOut=!!l,n.isCanceled=u,n.killed=c&&!l,n;},aE=["stdin","stdout","stderr"],aw=e=>aE.some(t=>void 0!==e[t]),ay=e=>{if(!e)return;let{stdio:t}=e;if(void 0===t)return aE.map(t=>e[t]);if(aw(e))throw Error("It's not possible to provide `stdio` in combination with one of "+aE.map(e=>`\`${e}\``).join(", "));if("string"==typeoft)returnt;if(!Array.isArray(t))throwTypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeoft}\``);returnArray.from({length:Math.max(t.length,aE.length)},(e,r)=>t[r]);},ab=(e,t="SIGTERM",r={})=>{letn=e(t);returnax(e,t,r,n),n;},ax=(e,t,r,n)=>{if(!aD(t,r,n))return;leti=setTimeout(()=>{e("SIGKILL");},aT(r));i.unref&&i.unref();},aD=(e,{forceKillAfterTimeout:t},r)=>aS(e)&&!1!==t&&r,aS=e=>e===p(rv).constants.signals.SIGTERM||"string"==typeofe&&"SIGTERM"===e.toUpperCase(),aT=({forceKillAfterTimeout:e=!0})=>{if(!0===e)return5e3;if(!Number.isFinite(e)||e<0)throwTypeError(`Expected the \`forceKillAfterTimeout\` option to be a non-negative integer, got \`${e}\` (${typeofe})`);returne;},aN=(e,t)=>{e.kill()&&(t.isCanceled=!0);},aI=(e,t,r)=>{e.kill(t),r(Object.assign(Error("Timed out"),{timedOut:!0,signal:t}));},aA=(e,{timeout:t,killSignal:r="SIGTERM"},n)=>{leti;return0===t||void0===t?n:Promise.race([newPromise((n,o)=>{i=setTimeout(()=>{aI(e,r,o);},t);}),n.finally(()=>{clearTimeout(i);})]);},aR=({timeout:e})=>{if(void0!==e&&(!Number.isFinite(e)||e<0))throwTypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${e}\` (${typeofe})`);},aO=async(e,{cleanup:t,detached:r},n)=>{if(!t||r)returnn;leti=p(r3)(()=>{e.kill();});returnn.finally(()=>{i();});},aC=e=>einstanceofrh.ChildProcess&&"function"==typeofe.then,a_=(e,t,r)=>{if("string"==typeofr)returne[t].pipe((0,rl.createWriteStream)(r)),e;if(b(r))returne[t].pipe(r),e;if(!aC(r))throwTypeError("The second argument must be a string, a stream or an Execa child process.");if(!b(r.stdin))throwTypeError("The target child process's stdin must be available.");returne[t].pipe(r.stdin),r;},aL=e=>{null!==e.stdout&&(e.pipeStdout=a_.bind(void0,e,"stdout")),null!==e.stderr&&(e.pipeStderr=a_.bind(void0,e,"stderr")),void0!==e.all&&(e.pipeAll=a_.bind(void0,e,"all"));},a$=e=>{if(void0!==e)throwTypeError("The `input` and `inputFile` options cannot be both set.");},aP=({input:e,inputFile:t})=>"string"!=typeoft?e:(a$(e),(0,rl.readFileSync)(t)),ak=e=>{lett=aP(e);if(y(t))throwTypeError("The `input` option cannot be a stream in sync mode");returnt;},aU=({input:e,inputFile:t})=>"string"!=typeoft?e:(a$(e),(0,rl.createReadStream)(t)),aF=(e,t)=>{letr=aU(t);void0!==r&&(y(r)?r.pipe(e.stdin):e.stdin.end(r));},aM=(e,{all:t})=>{if(!t||!e.stdout&&!e.stderr)return;letr=p(r7)();returne.stdout&&r.add(e.stdout),e.stderr&&r.add(e.stderr),r;},aj=async(e,t)=>{if(e&&void0!==t){e.destroy();try{returnawaitt;}catch(e){returne.bufferedData;}}},aq=(e,{encoding:t,buffer:r,maxBuffer:n})=>{if(e&&r)returnt?p(r4)(e,{encoding:t,maxBuffer:n}):p(r4).buffer(e,{maxBuffer:n});},aB=async({stdout:e,stderr:t,all:r},{encoding:n,buffer:i,maxBuffer:o},a)=>{lets=aq(e,{encoding:n,buffer:i,maxBuffer:o}),l=aq(t,{encoding:n,buffer:i,maxBuffer:o}),u=aq(r,{encoding:n,buffer:i,maxBuffer:2*o});try{returnawaitPromise.all([a,s,l,u]);}catch(n){returnPromise.all([{error:n,signal:n.signal,timedOut:n.timedOut},aj(e,s),aj(t,l),aj(r,u)]);}},aG=(async()=>{})().constructor.prototype,aH=["then","catch","finally"].map(e=>[e,Reflect.getOwnPropertyDescriptor(aG,e)]),aV=(e,t)=>{for(let[r,n]ofaH){leti="function"==typeoft?(...e)=>Reflect.apply(n.value,t(),e):n.value.bind(t);Reflect.defineProperty(e,r,{...n,value:i});}},aX=e=>newPromise((t,r)=>{e.on("exit",(e,r)=>{t({exitCode:e,signal:r});}),e.on("error",e=>{r(e);}),e.stdin&&e.stdin.on("error",e=>{r(e)
`);},a5=({env:e,extendEnv:t,preferLocal:r,localDir:n,execPath:i})=>{let o=t?{...p(rm).env,...e}:e;return r?w({env:o,cwd:n,execPath:i}):o;},a6=(e,t,r={})=>{let n=p(rB)._parse(e,t,r);return e=n.command,t=n.args,(r={maxBuffer:1e8,buffer:!0,stripFinalNewline:!0,extendEnv:!0,preferLocal:!1,localDir:(r=n.options).cwd||p(rm).cwd(),execPath:p(rm).execPath,encoding:"utf8",reject:!0,cleanup:!0,all:!1,windowsHide:!0,verbose:a1,...r}).env=a5(r),r.stdio=ay(r),"win32"===p(rm).platform&&"cmd"===p(rf).basename(e,".exe")&&t.unshift("/q"),{file:e,args:t,options:r,parsed:n};},a8=(e,t,r)=>"string"==typeof t||(0,rd.Buffer).isBuffer(t)?e.stripFinalNewline?v(t):t:void 0===r?void 0:"",a9=({input:e,inputFile:t,stdio:r})=>void 0===e&&void 0===t&&void 0===r?{stdin:"inherit"}:{},a7=(e={})=>({preferLocal:!0,...a9(e),...e});!function e(t){function r(n,...i){if(!Array.isArray(n))return e({...t,...n});let[o,...a]=a0(n,i);return k(o,a,a7(t));}return r.sync=(e,...r)=>{if(!Array.isArray(e))throw TypeError("Please use $(options).sync`command` instead of $.sync(options)`command`.");let[n,...i]=a0(e,r);return function(e,t,r){let n;let i=a6(e,t,r),o=aW(e,t),a=aK(e,t);a4(a,i.options);let s=ak(i.options);try{n=p(rh).spawnSync(i.file,i.args,{...i.options,input:s});}catch(e){throw av({error:e,stdout:"",stderr:"",all:"",command:o,escapedCommand:a,parsed:i,timedOut:!1,isCanceled:!1,killed:!1});}let l=a8(i.options,n.stdout,n.error),u=a8(i.options,n.stderr,n.error);if(n.error||0!==n.status||null!==n.signal){let e=av({stdout:l,stderr:u,error:n.error,signal:n.signal,exitCode:n.status,command:o,escapedCommand:a,parsed:i,timedOut:n.error&&"ETIMEDOUT"===n.error.code,isCanceled:!1,killed:null!==n.signal});if(!i.options.reject)return e;throw e;}return{command:o,escapedCommand:a,exitCode:0,stdout:l,stderr:u,failed:!1,timedOut:!1,isCanceled:!1,killed:!1};}(n,i,a7(t));},r;}(),nb={};const se="win32"!==n7.platform(),st=n7.release(),sr=(e="",t="")=>/1\d+\.\d+/.test(e)&&+t>=17134.1184;nb=function(e){return se?e.replace(/(\s+)/g,"\\$1"):sr(.../(\d+\.\d+)\.(\d+)/.exec(st).splice(1))?e:e.replace(/(\s+)/g,"%20");},function(){var e,t;e=rI("8CJZb"),t=function(e){return e.split("").reverse().join("");},nx=function(r,n,i){var o;return(null==n&&(n="'"),null==i&&(i="\\"),"string"!=typeof r)?r:(o=RegExp("(["+e(n)+"])(?!"+e(i)+")","g"),t(t(r).replace(o,"$1"+i)));};}.call(nx={}),nD=rI("6t4SD");const sn={shouldEscapeSpace:!1,shouldAddOnlyIfNotDefined:!1},si=[/\/usr\/bin\/?/,/\/usr\/local\/bin\/?/],so=C("~/.cpprc");let sa=!1;nD=rI("6t4SD"),nS=rI("f44Uw"),rO=rI("hHq4F");const{appendFile:ss}=it.promises;let sl=!1,su=!1;const sc=["E: Could not get lock","dpkg: error processing archive","dpkg: error: dpkg status database is locked by another process"];(rr=nT||(nT={}))[rr.NameDashVersion=0]="NameDashVersion",rr[rr.NameEqualsVersion=1]="NameEqualsVersion",rr[rr.Name=2]="Name",rr[rr.None=3]="None",ny=rI("1o3Gj"),nN=rI("eAXk4"),nN=rI("eAXk4"),nI=rI("zdagz");let sp=!1;nD=rI("6t4SD"),nN=rI("eAXk4"),rO=rI("hHq4F");let sd=!1;rO=rI("hHq4F"),rO=rI("hHq4F");let sf=!1,sh=!1;const sm=/Version\s*:\s*(.*)/g;nA={},nR=ie.resolve(__dirname,"../../node_modules/@actions/tool-cache/lib"),nO=nA&&nA.__createBinding||(Object.create?function(e,t,r,n){void 0===n&&(n=r),Object.defineProperty(e,n,{enumerable:!0,get:function(){return t[r];}});}:function(e,t,r,n){void 0===n&&(n=r),e[n]=t[r];}),nC=nA&&nA.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t});}:function(e,t){e.default=t;}),n_=nA&&nA.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)"default"!==r&&Object.hasOwnProperty.call(e,r)&&nO(t,e,r);return nC(t,e),t;},nL=nA&&nA.__awaiter||function(e,t,r,n){return new(r||(r=Promise))(function(i,o){function a(e){try{l(n.next(e));}catch(e){o(e);}}function s(e){try{l(n.throw(e));}catch(e){o(e);}}function l(e){var t;e.done?i(e.value):((t=e.value)instanceof r?t:new r(function(e){e(t);})).then(a,s);}l((n=n.apply(e,t||[])).next());});},n$=nA&&nA.__importDefault||function(e){return e&&e.__esModule?e:{default:e};},Object.defineProperty(nA,"__e