wailsapp / wails

Create beautiful applications using Go
https://wails.io
MIT License
23.56k stars 1.12k forks source link

wails 1 build fails to find .rc file (removes Slashes in path) #1985

Closed SimonStorlSchulke closed 1 year ago

SimonStorlSchulke commented 1 year ago

Description

(USING WAILS 1 - in WAILS 2 this doesn't happen!!!) I've got a rather strange problem. After initializing a project and when trying to build it, wails always fails to find the .rc file. The .rc file absolutely does exist. The path wails tries to use for it however has all / (slashes) removed. It says: cc1: fatal error: C:UserssimonDevwailstestwailstest.rc: No such file or directory - the correct location for the file would of course be C:/Users/simon/Dev/wailstest/wailstest.rc

Here is the full powershell output

PS C:\Users\simon\Dev> wails init
Wails v1.16.9 - Initialising project

The name of the project (My Project): wailstest
Project Name: wailstest
The output binary name (wailstest): wailstest
Output binary Name: wailstest
Project directory name (wailstest):
Project Directory: wailstest
Please select a template (* means unsupported on current platform):
  1: Angular - Angular 8 template (Requires node 10.8+)
  2: React JS - Create React App v4 template
  3: Svelte - A basic Svelte template
  4: Vanilla - A Vanilla HTML/JS template
  5: * Vue3 Full - Vue 3, Vuex, Vue-router, and Webpack4
  6: * Vue3 JS - A template based on Vue 3, Vue-router, Vuex, and Webpack5
  7: Vue2/Webpack Basic - A basic Vue2/WebPack4 template
  8: Vuetify1.5/Webpack Basic - A basic Vuetify1.5/Webpack4 template
  9: Vuetify2/Webpack Basic - A basic Vuetify2/Webpack4 template
Please choose an option [1]: 3
Template: Svelte
> Generating project...
Project 'wailstest' initialised. Run `wails build` to build it.
PS C:\Users\simon\Dev> cd .\wailstest\
PS C:\Users\simon\Dev\wailstest> wails build
Wails v1.16.9 - Building Application

> Ensuring frontend dependencies are up to date (This may take a while)
> Building frontend...
> Ensuring Dependencies are up to date...
cc1: fatal error: C:UserssimonDevwailstestwailstest.rc: No such file or directory
compilation terminated.
windres: preprocessing failed.

C:\Users\simon\Dev\wailstest>windres.exe -o C:\Users\simon\Dev\wailstest\wailstest-res.syso C:\Users\simon\Dev\wailstest\wailstest.rc

Error: exit status 1
PS C:\Users\simon\Dev\wailstest>

To Reproduce

I don't expect this to be reproducable on other machines. I exactly followed https://wails.app/gettingstarted/installing/

Expected behaviour

wails finding the .rc file

Screenshots

No response

Attempted Fixes

I tried to setup test projects in other directories. Always the same error.

System Details

**System Information**
Operating system: Windows-10-10.0.19043-SP0 64 Bits
Graphics card: NVIDIA RTX A4000/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 472.47
Prozessor: AMD Ryzen 9 5900X 12-Core Processor, 3701 MHz, 12 cores, 24 logic processors

*wails doctor doesn't work for me.

Additional context

No response

stffabi commented 1 year ago

Thanks for using Wails and reporting this issue.

It seems like you are using Wails v1, which is in feature-freeze and I think it also won't be actively maintained anymore since v2 has been released.

I would recommend you to take a look into v2, which has many new features and builds on top of Webview2 (Chromium Engine) on windows.