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);});});}r9(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=r6.sync(e.command,{path:n[r7({env:n})],pathExt:t?iv.delimiter:void0});}catch(e){}finally{a&&process.chdir(i);}returnr&&(r=iv.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){returnol&&1===e&&!t.file?h(t.original,"spawn"):null;}functiong(e,t,r){letn=r4(e,t,r),i=rS.spawn(n.command,n.args,n.options);returnno.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";}functiony({env:e=p(rO).env,...t}={}){letr=E({env:e={...e}});returnt.path=e[r],e[r]=function(e={}){lett;let{cwd:r=p(rO).cwd(),path:n=p(rO).env[E()],execPath:i=p(rO).execPath}=e,o=iinstanceofURL?p(rA).fileURLToPath(i):i,a=rinstanceofURL?p(rA).fileURLToPath(r):r,s=p(rR).resolve(a),l=[];for(;t!==s;)l.push(p(rR).join(s,"node_modules/.bin")),t=s,s=p(rR).resolve(s,"..");returnl.push(p(rR).resolve(a,o,"..")),[...l,n].join(p(rR).delimiter);}(t),e;}functionw(e){returnnull!==e&&"object"==typeofe&&"function"==typeofe.pipe;}functionb(e){returnw(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=nd(t);returnawaitnewPromise((t,i)=>{leto=e=>{e&&n.getBufferedLength()<=nc.MAX_LENGTH&&(e.bufferedData=n.getBufferedValue()),i(e);};(async()=>{try{awaito8(e,n),t();}catch(e){o(e);}})(),n.on("data",()=>{n.getBufferedLength()>r&&o(newo9());});}),n.getBufferedValue();}functionS(e,t,r){letn;leti=aT(e,t,r),o=ah(e,t),a=am(e,t);aD(a,i.options),o3(i.options);try{n=p(rI).spawn(i.file,i.args,i.options);}catch(t){lete=new(p(rI).ChildProcess)();returnac(e,Promise.reject(oO({error:t,stdout:"",stderr:"",all:"",command:o,escapedCommand:a,parsed:i,timedOut:!1,isCanceled:!1,killed:!1}))),e;}lets=ap(n),l=o1(n,i.options,s),u=o2(n,i.options,l),c={isCanceled:!1};n.kill=oY.bind(null,n.kill.bind(n)),n.cancel=oZ.bind(null,n,c);letd=na(async()=>{let[{error:e,exitCode:t,signal:r,timedOut:s},l,p,d]=awaitas(n,i.options,u),f=aR(i.options,l),h=aR(i.options,p),m=aR(i.options,d);if(e||0!==t||null!==r){letl=oO({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};});returnan(n,i.options),n.all=ai(n,i.options),o6(n),ac(n,d),n;}functionD(e,t,r){letn;leti=aT(e,t,r),o=ah(e,t),a=am(e,t);aD(a,i.options);lets=at(i.options);try{n=p(rI).spawnSync(i.file,i.args,{...i.options,input:s});}catch(e){throwoO({error:e,stdout:"",stderr:"",all:"",command:o,escapedCommand:a,parsed:i,timedOut:!1,isCanceled:!1,killed:!1});}letl=aR(i.options,n.stdout,n.error),u=aR(i.options,n.stderr,n.error);if(n.error||0!==n.status||null!==n.signal){lete=oO({stdout:l,stderr:u,error:n.error,signal:n.signal,exitCode:n.status,command:o,escapedCommand:a,parsed:i,timedOut:
`),(0,nP.info)(`${e}="${n}"wasaddedto"${sb}`));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,nP.info)(`"${e}" was added to the PATH.`);return;case"linux":case"darwin":awaitB(),(0,iE.appendFileSync)(sb,`
`),(0,nP.info)(`"${e}"wasaddedto"${sb}"`);return;default:return;}}async function B(){if(sx)return;let e="# Automatically Generated by setup-cpp\nexport SOURCE_CPPRC=0";if((await(0,nM.pathExists)(sb))&&(0,iE.readFileSync)(sb,"utf8").includes(e))return;(0,iE.appendFileSync)(sb,`
`),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 o=i.architecture??process.arch,a=process.env.SETUP_CPP_DIR??C("~"),s=[],l=[],u=rY.create({autoloadLocales:!0});rY.addLocale(p(rK)),rX.addLocale(p(rz));let c=await s0();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);}(i,["llvm","clangtidy","clangformat"]))return(0,rV.error)("The same version must be used for llvm, clangformat and clangtidy"),1;ea()&&"string"==typeof i.cppcheck&&"string"==typeof i.gcovr&&((0,rV.info)("installing python-pygments to avoid conflicts with cppcheck and gcovr on Arch linux"),await ed("python-pygments"));let d=!1,f=!1;for(let e of ur){if(rH.isCI&&0!==l.length){f=!0;break;}let n=i[e];void 0!==n&&(t=Date.now(),d=await tW(e,n,c,o,a,s,l,6e4*parseFloat(i.timeout??"20")),r=Date.now(),(0,rV.info)("took "+(u.format(t,r)||"0 seconds")));}if(!f){let e=i.compiler;if(void 0!==e){let t=Date.now();await rf(e,c,a,o,s,d,l);let r=Date.now();(0,rV.info)("took "+(u.format(t,r)||"0 seconds"));}}if(await G(),0===s.length&&0===l.length)return(0,rV.warning)("setup-cpp was called without any arguments. Nothing to do."),0;if(s.forEach(e=>(0,rV.success)(e)),l.forEach(e=>(0,rV.error)(e)),(0,rV.info)("setup-cpp finished"),!rH.GITHUB_ACTIONS)switch(process.platform){case"win32":(0,rV.warning)("Run `RefreshEnv.cmd` or restart your shell to update the environment.");break;case"linux":case"darwin":(0,rV.warning)("Run `source~/.cpprc`orrestartyourshelltoupdatetheenvironment.");}returnawaitn,0===l.length?0:1;}varrm,rg,rv,rE,ry,rw,rb,rx,rS,rD,rN,rT,rR,rI,rO,rA,rC,r_,rL,r$,rP,rk,rU,rM,rF,rj,rq,rB,rG,rH,rV,rX,rz,rY,rK,rW,rJ,rQ,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,ny,nw,nb,nx,nS,nD,nN,nT,nR,nI,nO,nA,nC,n_,nL,n$,nP,nk,nU,nM,nF,nj,nq,nB,nG,nH,nV,nX,nz,nY,nK,nW,nJ,nQ,nZ,n0,n1,n3,n2,n4,n5,n6,n8,n9,n7,ie,it,ir,ii,io,ia,is,il,iu,ic,ip,id,ih,im,ig=require("os"),iv=require("path"),iE=require("fs"),iy=require("crypto"),iw=require("http"),ib=require("https");require("net"),rE=require("tls"),ry=require("events"),rw=require("assert"),rb=require("util"),rx=require("fs"),rS=require("child_process"),rD=require("string_decoder"),rN=require("timers"),rT=require("buffer"),rR=require("path"),rI=require("child_process"),rO=require("process"),rA=require("url"),rC=require("os"),r_=require("buffer"),rL=require("stream"),r$=require("util"),rP=require("process"),rk=require("url"),rU=require("stream"),rM=require("console"),rj={},rq={},null==(rB=(rF=globalThis).parcelRequire810d)&&((rB=function(e){if(einrj)returnrj[e].exports;if(einrq){vart=rq[e];deleterq[e];varr={id:e,exports:{}};returnrj[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){rq[e]=t;},rF.parcelRequire810d=rB),(rG=rB.register)("52cQ1",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=rB("jgqtC");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"int.pr?e.exports.isPR=t.pr.any.some(functio
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;}),rG("a7JAS",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(iw),d=i(ib),f=i(rB("8gh3V")),h=i(rB("7i1qo"));(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 y{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=y,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}`,of=Object.getOwnPropertyDescriptor(Function.prototype,"toString"),oh=Object.getOwnPropertyDescriptor(Function.prototype.toString,"name"),om=(e,t,r)=>{let n=""===r?"":`with${r.trim()}()`,i=od.bind(null,n,t.toString());Object.defineProperty(i,"name",oh),Object.defineProperty(e,"toString",{...of,value:i});},og=new WeakMap(),ov=(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(og.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))ou(e,t,n,r);op(e,t),om(e,t,n);}(o,e),og.set(o,n),o;};ov.callCount=e=>{if(!og.has(e))throwError(`The given function \`${e.name}\` is not wrapped by the \`onetime\` package`);returnog.get(e);},na=ov;constoE=()=>Array.from({length:ob-ow+1},oy),oy=(e,t)=>({name:"SIGRT"+(t+1),number:ow+t,action:"terminate",description:"Application-specific signal (realtime)",standard:"posix"}),ow=34,ob=64,ox=[{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,y=[E,t,e].filter(Boolean).join("\n");return v?(n.originalMessage=n.message,n.message=y):n=Error(y),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;},oA=["stdin","stdout","stderr"],oC=e=>oA.some(t=>void 0!==e[t]),o_=e=>{if(!e)return;let{stdio:t}=e;if(void 0===t)return oA.map(t=>e[t]);if(oC(e))throw Error("It's not possible to provide `stdio` in combination with one of "+oA.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,oA.length)},(e,r)=>t[r]);};ns={};constoL=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(oL(nl=rF.process)){varo$,oP=rw,ok=rB("e1Rfe"),oU=/^win/i.test(nl.platform),oM=ry;"function"!=typeofoM&&(oM=oM.EventEmitter),nl.__signal_exit_emitter__?o$=nl.__signal_exit_emitter__:((o$=nl.__signal_exit_emitter__=newoM()).count=0,o$.emitted={}),o$.infinite||(o$.setMaxListeners(1/0),o$.infinite=!0);varoF=function(){oB&&oL(rF.process)&&(oB=!1,ok.forEach(function(e){try{nl.removeListener(e,oq[e]);}catch(e){}}),nl.emit=oX,nl.reallyExit=oH,o$.count-=1);};(ns=function(e,t){if(!oL(rF.process))returnfunction(){};oP.equal(typeofe,"function","a callback must be provided for exit handler"),!1===oB&&oG();varr="exit";returnt&&t.alwaysLast&&(r="afterexit"),o$.on(r,e),function(){o$.removeListener(r,e),0===o$.listeners("exit").length&&0===o$.listeners("afterexit").length&&oF();};}).unload=oF;varoj=function(e,t,r){o$.emitted[e]||(o$.emitted[e]=!0,o$.emit(e,t,r));},oq={};ok.forEach(function(e){oq[e]=function(){oL(rF.process)&&nl.listeners(e).length===o$.count&&(oF(),oj("exit",null,e),oj("afterexit",null,e),oU&&"SIGHUP"===e&&(e="SIGINT"),nl.kill(nl.pid,e));};}),ns.signals=function(){returnok;};varoB=!1,oG=function(){!oB&&oL(rF.process)&&(oB=!0,o$.count+=1,ok=ok.filter(function(e){try{returnnl.on(e,oq[e]),!0;}catch(e){return!1;}}),nl.emit=oz,nl.reallyExit=oV);};ns.load=oG;varoH=nl.reallyExit,oV=function(e){oL(rF.process)&&(nl.exitCode=e||0,oj("exit",nl.exitCode,null),oj("afterexit",nl.exitCode,null),oH.call(nl,nl.exitCode));},oX=nl.emit,oz=function(e,t){if(!("exit"===e&&oL(rF.process)))returnoX.apply(this,arguments);void0!==t&&(nl.exitCode=t);varr=oX.apply(this,arguments);returnoj("exit",nl.exitCode,null),oj("afterexit",nl.exitCode,null),r;};}elsens=function(){returnfunction(){};};constoY=(e,t="SIGTERM",r={})=>{letn=e(t);returnoK(e,t,r,n),n;},oK=(e,t,r,n)=>{if(!oW(t,r,n))return;leti=setTimeout(()=>{e("SIGKILL");},oQ(r));i.unref&&i.unref();},oW=(e,{forceKillAfterTimeout:t},r)=>oJ(e)&&!1!==t&&r,oJ=e=>e===p(rC).constants.signals.SIGTERM||"string"==typeofe&&"SIGTERM"===e.toUpperCase(),oQ=({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;},oZ=(e,t)=>{e.kill()&&(t.isCanceled=!0);},o0=(e,t,r)=>{e.kill(t),r(Object.assign(Error("Timed out"),{timedOut:!0,signal:t}));},o1=(e,{timeout:t,killSignal:r="SIGTERM"},n)=>{leti;return0===t||void0===t?n:Promise.race([newPromise((n,o)=>{i=setTimeout(()=>{o0(e,r,o);},t);}),n.finally(()=>{clearTimeout(i);})]);},o3=({timeout:e})=>{if(void0!==e&&(!Number.isFinite(e)||e<0))throwTypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${e}\` (${typeofe})`);},o2=async(e,{cleanup:t,detached:r},n)=>{if(!t||r)returnn;leti=p(ns)(()=>{e.kill();});returnn.finally(()=>{i();});},o4=e=>einstanceofrI.ChildProcess&&"function"==typeofe.then,o5=(e,t,r)=>{if("string"==typeofr)returne[t].pipe((0,rx.createWriteStream)(r)),e;if(b
`);},aN=({env:e,extendEnv:t,preferLocal:r,localDir:n,execPath:i})=>{let o=t?{...p(rO).env,...e}:e;return r?y({env:o,cwd:n,execPath:i}):o;},aT=(e,t,r={})=>{let n=p(r2)._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(rO).cwd(),execPath:p(rO).execPath,encoding:"utf8",reject:!0,cleanup:!0,all:!1,windowsHide:!0,verbose:ab,...r}).env=aN(r),r.stdio=o_(r),"win32"===p(rO).platform&&"cmd"===p(rR).basename(e,".exe")&&t.unshift("/q"),{file:e,args:t,options:r,parsed:n};},aR=(e,t,r)=>"string"==typeof t||(0,rT.Buffer).isBuffer(t)?e.stripFinalNewline?v(t):t:void 0===r?void 0:"",aI=({input:e,inputFile:t,stdio:r})=>void 0===e&&void 0===t&&void 0===r?{stdin:"inherit"}:{},aO=(e={})=>({preferLocal:!0,...aI(e),...e});!function e(t){function r(n,...i){if(!Array.isArray(n))return e({...t,...n});let[o,...a]=aw(n,i);return S(o,a,aO(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]=aw(e,r);return D(n,i,aO(t));},r;}();const aA={stdio:"inherit",shell:!0},aC=/^~(?=$|\/|\\)/;rV=rB("ER74K"),ng={},nv=rB("bSUdl"),nE=rP.env.npm_package_json,nw=!!((ny=rP.env.npm_config_user_agent)&&ny.startsWith("npm")),nb=!!(nE&&nE.endsWith("package.json")),nx=nw||nb,nS=!!(ny&&ny.startsWith("yarn")),nD=nx||nS,nN=ig.homedir(),nT=process.env.XDG_CONFIG_HOME||iv.join(nN,".config","simple-update-notifier"),nR=function(e){return iv.join(nT,"".concat(e.replace("@","").replace("/","__"),".json"));},nI=function(){iE.existsSync(nT)||iE.mkdirSync(nT,{recursive:!0});},nO=function(e){var t=nR(e);try{if(!iE.existsSync(t))return;return JSON.parse(iE.readFileSync(t,"utf8")).lastUpdateCheck;}catch(e){return;}},nA=function(e){var t=nR(e);iE.writeFileSync(t,JSON.stringify({lastUpdateCheck:new Date().getTime()}));},nC=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){ib.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);});})];});});},n_=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(nI(),e=nO(t.name),!(a||!e||e<new Date().getTime()-n))return[3,2];return[4,nC(t.name,o)];case 1:if(r=i.sent(),nA(t.name),nv.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];}});});},nL=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");},ng=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||nD&&!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,n_(e)];case 2:return(t=n.sent())&&console.error(nL("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];}});});},n$={},n$=JSON.parse('{"name":"setup-cpp","version":"0.36.2"}'),nP=rB("4t50X"),rV=rB("ER74K"),rH
${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;},a$=["stdin","stdout","stderr"],aP=e=>a$.some(t=>void 0!==e[t]),ak=e=>{if(!e)return;let{stdio:t}=e;if(void 0===t)return a$.map(t=>e[t]);if(aP(e))throw Error("It's not possible to provide `stdio` in combination with one of "+a$.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,a$.length)},(e,r)=>t[r]);},aU=(e,t="SIGTERM",r={})=>{letn=e(t);returnaM(e,t,r,n),n;},aM=(e,t,r,n)=>{if(!aF(t,r,n))return;leti=setTimeout(()=>{e("SIGKILL");},aq(r));i.unref&&i.unref();},aF=(e,{forceKillAfterTimeout:t},r)=>aj(e)&&!1!==t&&r,aj=e=>e===p(rC).constants.signals.SIGTERM||"string"==typeofe&&"SIGTERM"===e.toUpperCase(),aq=({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;},aB=(e,t)=>{e.kill()&&(t.isCanceled=!0);},aG=(e,t,r)=>{e.kill(t),r(Object.assign(Error("Timed out"),{timedOut:!0,signal:t}));},aH=(e,{timeout:t,killSignal:r="SIGTERM"},n)=>{leti;return0===t||void0===t?n:Promise.race([newPromise((n,o)=>{i=setTimeout(()=>{aG(e,r,o);},t);}),n.finally(()=>{clearTimeout(i);})]);},aV=({timeout:e})=>{if(void0!==e&&(!Number.isFinite(e)||e<0))throwTypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${e}\` (${typeofe})`);},aX=async(e,{cleanup:t,detached:r},n)=>{if(!t||r)returnn;leti=p(ns)(()=>{e.kill();});returnn.finally(()=>{i();});},az=e=>einstanceofrI.ChildProcess&&"function"==typeofe.then,aY=(e,t,r)=>{if("string"==typeofr)returne[t].pipe((0,rx.createWriteStream)(r)),e;if(b(r))returne[t].pipe(r),e;if(!az(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;},aK=e=>{null!==e.stdout&&(e.pipeStdout=aY.bind(void0,e,"stdout")),null!==e.stderr&&(e.pipeStderr=aY.bind(void0,e,"stderr")),void0!==e.all&&(e.pipeAll=aY.bind(void0,e,"all"));},aW=e=>{if(void0!==e)throwTypeError("The `input` and `inputFile` options cannot be both set.");},aJ=({input:e,inputFile:t})=>"string"!=typeoft?e:(aW(e),(0,rx.readFileSync)(t)),aQ=e=>{lett=aJ(e);if(w(t))throwTypeError("The `input` option cannot be a stream in sync mode");returnt;},aZ=({input:e,inputFile:t})=>"string"!=typeoft?e:(aW(e),(0,rx.createReadStream)(t)),a0=(e,t)=>{letr=aZ(t);void0!==r&&(w(r)?r.pipe(e.stdin):e.stdin.end(r));},a1=(e,{all:t})=>{if(!t||!e.stdout&&!e.stderr)return;letr=p(nh)();returne.stdout&&r.add(e.stdout),e.stderr&&r.add(e.stderr),r;},a3=async(e,t)=>{if(e&&void0!==t){e.destroy();try{returnawaitt;}catch(e){returne.bufferedData;}}},a2=(e,{encoding:t,buffer:r,maxBuffer:n})=>{if(e&&r)returnt?p(nu)(e,{encoding:t,maxBuffer:n}):p(nu).buffer(e,{maxBuffer:n});},a4=async({stdout:e,stderr:t,all:r},{encoding:n,buffer:i,maxBuffer:o},a)=>{lets=a2(e,{encoding:n,buffer:i,maxBuffer:o}),l=a2(t,{encoding:n,buffer:i,maxBuffer:o}),u=a2(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},a3(e,s),a3(t,l),a3(r,u)]);}},a5=(async()=>{})().constructor.prototype,a6=["then","catch","finally"].map(e=>[e,Reflect.getOwnPropertyDescriptor(a5,e)]),a8=(e,t)=>{for(let[r,n]ofa6){leti="function"==typeoft?(...e)=>Reflect.apply(n.value,t(),e):n.value.bind(t);Reflect.defineProperty(e,r,{...n,value:i});}},a9=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)
`);},sp=({env:e,extendEnv:t,preferLocal:r,localDir:n,execPath:i})=>{let o=t?{...p(rO).env,...e}:e;return r?y({env:o,cwd:n,execPath:i}):o;},sd=(e,t,r={})=>{let n=p(r2)._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(rO).cwd(),execPath:p(rO).execPath,encoding:"utf8",reject:!0,cleanup:!0,all:!1,windowsHide:!0,verbose:ss,...r}).env=sp(r),r.stdio=ak(r),"win32"===p(rO).platform&&"cmd"===p(rR).basename(e,".exe")&&t.unshift("/q"),{file:e,args:t,options:r,parsed:n};},sf=(e,t,r)=>"string"==typeof t||(0,rT.Buffer).isBuffer(t)?e.stripFinalNewline?v(t):t:void 0===r?void 0:"",sh=({input:e,inputFile:t,stdio:r})=>void 0===e&&void 0===t&&void 0===r?{stdin:"inherit"}:{},sm=(e={})=>({preferLocal:!0,...sh(e),...e});!function e(t){function r(n,...i){if(!Array.isArray(n))return e({...t,...n});let[o,...a]=sa(n,i);return k(o,a,sm(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]=sa(e,r);return function(e,t,r){let n;let i=sd(e,t,r),o=st(e,t),a=sr(e,t);sc(a,i.options);let s=aQ(i.options);try{n=p(rI).spawnSync(i.file,i.args,{...i.options,input:s});}catch(e){throw aL({error:e,stdout:"",stderr:"",all:"",command:o,escapedCommand:a,parsed:i,timedOut:!1,isCanceled:!1,killed:!1});}let l=sf(i.options,n.stdout,n.error),u=sf(i.options,n.stderr,n.error);if(n.error||0!==n.status||null!==n.signal){let e=aL({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,sm(t));},r;}(),nk={};const sg="win32"!==ig.platform(),sv=ig.release(),sE=(e="",t="")=>/1\d+\.\d+/.test(e)&&+t>=17134.1184;nk=function(e){return sg?e.replace(/(\s+)/g,"\\$1"):sE(.../(\d+\.\d+)\.(\d+)/.exec(sv).splice(1))?e:e.replace(/(\s+)/g,"%20");},function(){var e,t;e=rB("i8A01"),t=function(e){return e.split("").reverse().join("");},nU=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(nU={}),nM=rB("kY0n1");const sy={shouldEscapeSpace:!1,shouldAddOnlyIfNotDefined:!1},sw=[/\/usr\/bin\/?/,/\/usr\/local\/bin\/?/],sb=C("~/.cpprc");let sx=!1;nM=rB("kY0n1"),nF=rB("iNGpn"),rV=rB("ER74K");const{appendFile:sS}=iE.promises;let sD=!1,sN=!1;const sT=["E: Could not get lock","dpkg: error processing archive","dpkg: error: dpkg status database is locked by another process"];(rm=nj||(nj={}))[rm.NameDashVersion=0]="NameDashVersion",rm[rm.NameEqualsVersion=1]="NameEqualsVersion",rm[rm.Name=2]="Name",rm[rm.None=3]="None",nP=rB("4t50X"),nq=rB("bzNgi"),nq=rB("bzNgi"),nB=rB("hZdK0");let sR=!1;nM=rB("kY0n1"),nq=rB("bzNgi"),rV=rB("ER74K");let sI=!1;rV=rB("ER74K"),rV=rB("ER74K");let sO=!1,sA=!1;const sC=/Version\s*:\s*(.*)/g;nG={},nH=iv.resolve(__dirname,"../../node_modules/@actions/tool-cache/lib"),nV=nG&&nG.__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];}),nX=nG&&nG.__setModuleDefault||(Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t});}:function(e,t){e.default=t;}),nz=nG&&nG.__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)&&nV(t,e,r);return nX(t,e),t;},nY=nG&&nG.__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());});},nK=nG&&nG.__importDefault||function(e){return e&&e.__esModule?e:{default:e};},Object.defineProperty(nG,"__e