0

When trying to create a Chocolatey package for ARM RVDS 4.1, it fails and I am not sure what the issue is. I believe I either set up the chocolateyinstall.ps1 incorrectly or something with the setup.exe being in the tools folder.

Here is the error I get in the cmd: https://ibb.co/KmDPxcF

Here is the chocolateyinstall.ps1: https://ibb.co/yR7ysqR

Here is the .nuspec: https://ibb.co/hBM3xn9

Here is a look inside the tools folder: https://ibb.co/8NGXPNW

Can I not use the environment variable as the file location in the chocolateyinstall.ps1? Or is it a different problem? I also have suspicion that I might be using the wrong silentArg.

Edit: I have found some info on why the error says access is denied, but it all relates to an antivirus, which I don't have.

DeZLearnsPCs
  • 81
  • 2
  • 9
  • 1
    A quick look shows one of the errors is just "access is denied" - are you running as admin? – Matthew Mar 03 '20 at 14:57
  • 1
    show more you code, error tell that problem in some invoke method called Start, show this fragment of your code.And show log file chocolatey. – Vad Mar 03 '20 at 14:58
  • @Matthew @Vad I was running as an admin and this is all the code I have besides the batch script that actually tries to install the package. But all the batch file has is just: `choco install armrvds -r -y`. – DeZLearnsPCs Mar 03 '20 at 15:00

1 Answers1

1

As per the documentation here:

https://chocolatey.org/docs/helpers-install-chocolatey-install-package#file-string

Full file path to native installer to run. If embedding in the package, you can get it to the path with "$(Split-Path -parent $MyInvocation.MyCommand.Definition)\INSTALLER_FILE"

In 0.10.1+, FileFullPath is an alias for File.

This can be a 32-bit or 64-bit file. This is mandatory in earlier versions of Chocolatey, but optional if File64 has been provided.

You are currently passing a directory to the file parameter, which is incorrect.

Gary Ewan Park
  • 17,610
  • 5
  • 42
  • 60
  • After changing the `chocolateyinstall.ps1` to have `File: $(Split-Path -parent $MyInvocation.MyCommand.Definition)\setup.exe`, it gives me an error saying "Exception calling "Start" with "0" argument(s): "The system cannot find the file specified". – DeZLearnsPCs Mar 04 '20 at 14:26