Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Fedora41/42] Wails Doctor cannot detect gcc and libraries installation correctly #4011

Open
inlann opened this issue Jan 15, 2025 · 8 comments
Labels
External Issue Not a Wails issue but something wrong with an external dependency

Comments

@inlann
Copy link

inlann commented Jan 15, 2025

Description

Hello,

It seems like Wails Doctor cannot detect gcc and dependency libraries installation correctly:

root@localhost-live:~# wails doctor

                                
          Wails Doctor          
                                

                                                                                                                                                                                
# Wails
Version         | v2.9.2
Package Manager | dnf   

# System
┌──────────────────────────────────────────────────────┐
| OS           | Fedora Linux                          |
| Version      | 41                                    |
| ID           | fedora                                |
| Go Version   | go1.23.4                              |
| Platform     | linux                                 |
| Architecture | amd64                                 |
| CPU          | QEMU Virtual CPU version 2.5+         |
| GPU          | unknown (unknown) - Driver: bochs-drm |
| Memory       | 16GB                                  |
└──────────────────────────────────────────────────────┘

# Dependencies
┌────────────────────────────────────────────────────────┐
| Dependency | Package Name        | Status    | Version |
| *docker    | moby-engine         | Installed | 27.3.1  |
| gcc        | gcc-c++             | Installed | 14.2.1  |
| libgtk-3   | gtk3-devel          | Installed | 3.24.43 |
| libwebkit  | webkit2gtk4.0-devel | Installed | 2.46.3  |
| npm        | nodejs-npm          | Installed | 10.9.0  |
| pkg-config | pkgconf-pkg-config  | Installed | 2.3.0   |
| *upx       | upx                 | Installed | 4.2.4   |
└─────────────── * - Optional Dependency ────────────────┘

# Diagnosis
 SUCCESS  Your system is ready for Wails development!

 ♥   If Wails is useful to you or your company, please consider sponsoring the project:
https://github.com/sponsors/leaanthony
root@localhost-live:~# gcc --version
bash: gcc: command not found...
root@localhost-live:~# cp -r /share/rd/temp/infra/wails_test .
root@localhost-live:~# ls
anaconda-ks.cfg  go  go1.23.4.linux-amd64.tar.gz  wails_test
root@localhost-live:~# cd wails_test/
root@localhost-live:~/wails_test# ls
app.go  build  frontend  go.mod  go.sum  main.go  README.md  wails.json
root@localhost-live:~/wails_test# rm build/bin/wails_test 
rm: remove regular file 'build/bin/wails_test'? y
root@localhost-live:~/wails_test# wails build/
Wails CLI v2.9.2

Available commands:

   build      Builds the application 
   dev        Runs the application in development mode 
   doctor     Diagnose your environment 
   init       Initialises a new Wails project 
   update     Update the Wails CLI 
   show       Shows various information 
   generate   Code Generation Tools 
   version    The Wails CLI version 

Flags:

  -help
    	Get help on the 'wails' command.

 ♥   If Wails is useful to you or your company, please consider sponsoring the project:
https://github.com/sponsors/leaanthony
root@localhost-live:~/wails_test# wails build
Wails CLI v2.9.2


# Build Options

Platform(s)        | linux/amd64              
Compiler           | /usr/local/go/bin/go     
Skip Bindings      | false                    
Build Mode         | production               
Devtools           | false                    
Frontend Directory | /root/wails_test/frontend
Obfuscated         | false                    
Skip Frontend      | false                    
Compress           | false                    
Package            | true                     
Clean Bin Dir      | false                    
LDFlags            |                          
Tags               | []                       
Race Detector      | false                    

# Building target: linux/amd64

  • Generating bindings: Done.
  • Installing frontend dependencies: Done.
  • Compiling frontend: Done.
  • Compiling application: # runtime/cgo
cgo: C compiler "gcc" not found: exec: "gcc": executable file not found in $PATH
  ERROR   exit status 1

  ERROR   exit status 1
 ♥   If Wails is useful to you or your company, please consider sponsoring the project:
https://github.com/sponsors/leaanthony
root@localhost-live:~/wails_test#

wails_test is my demo project. I have tried on Fedora 41 virtual machine and Fedora 42 docker images. The output is same:

[root@35a7d0a929ba wails_test]# wails doctor

                                
          Wails Doctor          
                                

                                                                                                                                                                                
# Wails
Version         | v2.9.2
Package Manager | dnf   

# System
┌────────────────────────────────────────────────┐
| OS           | Fedora Linux                    |
| Version      | 41                              |
| ID           | fedora                          |
| Go Version   | go1.23.4                        |
| Platform     | linux                           |
| Architecture | amd64                           |
| CPU          | AMD EPYC 7763 64-Core Processor |
| Memory       | 32GB                            |
└────────────────────────────────────────────────┘

# Dependencies
┌────────────────────────────────────────────────────────┐
| Dependency | Package Name        | Status    | Version |
| *docker    | moby-engine         | Installed | 27.3.1  |
| gcc        | gcc-c++             | Installed | 14.2.1  |
| libgtk-3   | gtk3-devel          | Installed | 3.24.43 |
| libwebkit  | webkit2gtk4.0-devel | Installed | 2.46.3  |
| npm        | nodejs-npm          | Installed | 10.9.0  |
| pkg-config | pkgconf-pkg-config  | Installed | 2.3.0   |
| *upx       | upx                 | Installed | 4.2.4   |
└─────────────── * - Optional Dependency ────────────────┘

# Diagnosis
 SUCCESS  Your system is ready for Wails development!

 ♥   If Wails is useful to you or your company, please consider sponsoring the project:
https://github.com/sponsors/leaanthony
[root@35a7d0a929ba wails_test]# ls
README.md  app.go  build  frontend  go.mod  go.sum  main.go  wails.json
[root@35a7d0a929ba wails_test]# wails build
Wails CLI v2.9.2


# Build Options

Platform(s)        | linux/amd64              
Compiler           | /usr/local/go/bin/go     
Skip Bindings      | false                    
Build Mode         | production               
Devtools           | false                    
Frontend Directory | /root/wails_test/frontend
Obfuscated         | false                    
Skip Frontend      | false                    
Compress           | false                    
Package            | true                     
Clean Bin Dir      | false                    
LDFlags            |                          
Tags               | []                       
Race Detector      | false                    

# Building target: linux/amd64

  • Generating bindings: Done.
  • Installing frontend dependencies: Done.
  • Compiling frontend: Done.
  • Compiling application: # runtime/cgo
cgo: C compiler "gcc" not found: exec: "gcc": executable file not found in $PATH
  ERROR   exit status 1

  ERROR   exit status 1
 ♥   If Wails is useful to you or your company, please consider sponsoring the project:
https://github.com/sponsors/leaanthony
[root@35a7d0a929ba wails_test]#
[root@35a7d0a929ba wails_test]# dnf install -y gcc
Updating and loading repositories:
Repositories loaded.
Package                                                    Arch           Version                                                     Repository                            Size
Installing:
 gcc                                                       x86_64         14.2.1-7.fc41                                               updates                          103.4 MiB
Installing dependencies:
 binutils                                                  x86_64         2.43.1-5.fc41                                               updates                           27.4 MiB
 cpp                                                       x86_64         14.2.1-7.fc41                                               updates                           34.5 MiB
 elfutils-debuginfod-client                                x86_64         0.192-7.fc41                                                updates                           81.4 KiB
 glibc-devel                                               x86_64         2.40-17.fc41                                                updates                            2.3 MiB
 jansson                                                   x86_64         2.13.1-10.fc41                                              fedora                            88.3 KiB
 kernel-headers                                            x86_64         6.12.4-200.fc41                                             updates                            6.4 MiB
 libmpc                                                    x86_64         1.3.1-6.fc41                                                fedora                           164.7 KiB
 libxcrypt-devel                                           x86_64         4.4.37-4.fc41                                               updates                           30.5 KiB
 make                                                      x86_64         1:4.4.1-8.fc41                                              fedora                             1.8 MiB

Transaction Summary:
 Installing:        10 packages

Total size of inbound packages is 57 MiB. Need to download 57 MiB.
After this operation, 176 MiB extra will be used (install 176 MiB, remove 0 B).
[ 1/10] libmpc-0:1.3.1-6.fc41.x86_64                                                                                                    100% | 283.3 KiB/s |  71.1 KiB |  00m00s
[ 2/10] make-1:4.4.1-8.fc41.x86_64                                                                                                      100% |   1.6 MiB/s | 586.1 KiB |  00m00s
[ 3/10] binutils-0:2.43.1-5.fc41.x86_64                                                                                                 100% |   5.1 MiB/s |   6.3 MiB |  00m01s
[ 4/10] jansson-0:2.13.1-10.fc41.x86_64                                                                                                 100% | 186.7 KiB/s |  44.4 KiB |  00m00s
[ 5/10] cpp-0:14.2.1-7.fc41.x86_64                                                                                                      100% |   5.8 MiB/s |  11.5 MiB |  00m02s
[ 6/10] glibc-devel-0:2.40-17.fc41.x86_64                                                                                               100% |   1.4 MiB/s | 626.6 KiB |  00m00s
[ 7/10] elfutils-debuginfod-client-0:0.192-7.fc41.x86_64                                                                                100% | 190.7 KiB/s |  43.9 KiB |  00m00s
[ 8/10] kernel-headers-0:6.12.4-200.fc41.x86_64                                                                                         100% |   3.6 MiB/s |   1.6 MiB |  00m00s
[ 9/10] libxcrypt-devel-0:4.4.37-4.fc41.x86_64                                                                                          100% |  95.2 KiB/s |  28.3 KiB |  00m00s
[10/10] gcc-0:14.2.1-7.fc41.x86_64                                                                                                      100% |   7.7 MiB/s |  36.1 MiB |  00m05s
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
[10/10] Total                                                                                                                           100% |   9.5 MiB/s |  56.9 MiB |  00m06s
Running transaction
[ 1/12] Verify package files                                                                                                            100% |  58.0   B/s |  10.0   B |  00m00s
[ 2/12] Prepare transaction                                                                                                             100% | 204.0   B/s |  10.0   B |  00m00s
[ 3/12] Installing libmpc-0:1.3.1-6.fc41.x86_64                                                                                         100% |  11.6 MiB/s | 166.2 KiB |  00m00s
[ 4/12] Installing cpp-0:14.2.1-7.fc41.x86_64                                                                                           100% | 261.8 MiB/s |  34.6 MiB |  00m00s
[ 5/12] Installing kernel-headers-0:6.12.4-200.fc41.x86_64                                                                              100% |  47.8 MiB/s |   6.6 MiB |  00m00s
[ 6/12] Installing libxcrypt-devel-0:4.4.37-4.fc41.x86_64                                                                               100% |   2.9 MiB/s |  32.9 KiB |  00m00s
[ 7/12] Installing glibc-devel-0:2.40-17.fc41.x86_64                                                                                    100% |  31.8 MiB/s |   2.3 MiB |  00m00s
[ 8/12] Installing elfutils-debuginfod-client-0:0.192-7.fc41.x86_64                                                                     100% |   7.4 MiB/s |  83.8 KiB |  00m00s
[ 9/12] Installing jansson-0:2.13.1-10.fc41.x86_64                                                                                      100% |  12.5 MiB/s |  89.7 KiB |  00m00s
[10/12] Installing binutils-0:2.43.1-5.fc41.x86_64                                                                                      100% | 249.0 MiB/s |  27.4 MiB |  00m00s
[11/12] Installing make-1:4.4.1-8.fc41.x86_64                                                                                           100% | 105.9 MiB/s |   1.8 MiB |  00m00s
[12/12] Installing gcc-0:14.2.1-7.fc41.x86_64                                                                                           100% | 108.2 MiB/s | 103.4 MiB |  00m01s
Complete!
[root@35a7d0a929ba wails_test]# gcc --version
gcc (GCC) 14.2.1 20250110 (Red Hat 14.2.1-7)
Copyright (C) 2024 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

[root@35a7d0a929ba wails_test]# wails build
Wails CLI v2.9.2


# Build Options

Platform(s)        | linux/amd64              
Compiler           | /usr/local/go/bin/go     
Skip Bindings      | false                    
Build Mode         | production               
Devtools           | false                    
Frontend Directory | /root/wails_test/frontend
Obfuscated         | false                    
Skip Frontend      | false                    
Compress           | false                    
Package            | true                     
Clean Bin Dir      | false                    
LDFlags            |                          
Tags               | []                       
Race Detector      | false                    

# Building target: linux/amd64

  • Generating bindings: Done.
  • Installing frontend dependencies: Done.
  • Compiling frontend: Done.
  • Compiling application: # github.com/wailsapp/wails/v2/pkg/assetserver/webview
# [pkg-config --cflags  -- gtk+-3.0 gio-unix-2.0 webkit2gtk-4.0 gtk+-3.0 gio-unix-2.0 webkit2gtk-4.0 gtk+-3.0 webkit2gtk-4.0]
Package gtk+-3.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gtk+-3.0.pc'
to the PKG_CONFIG_PATH environment variable
Package 'gtk+-3.0' not found
Package 'gio-unix-2.0' not found
Package 'webkit2gtk-4.0' not found
Package 'gtk+-3.0' not found
Package 'gio-unix-2.0' not found
Package 'webkit2gtk-4.0' not found
Package 'gtk+-3.0' not found
Package 'webkit2gtk-4.0' not found
  ERROR   exit status 1

  ERROR   exit status 1
 ♥   If Wails is useful to you or your company, please consider sponsoring the project:
https://github.com/sponsors/leaanthony
[root@35a7d0a929ba wails_test]# pkg-config --cflags  -- gtk+-3.0 gio-unix-2.0 webkit2gtk-4.0 gtk+-3.0 gio-unix-2.0 webkit2gtk-4.0 gtk+-3.0 webkit2gtk-4.0
Package gtk+-3.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gtk+-3.0.pc'
to the PKG_CONFIG_PATH environment variable
Package 'gtk+-3.0' not found
Package 'gio-unix-2.0' not found
Package 'webkit2gtk-4.0' not found
Package 'gtk+-3.0' not found
Package 'gio-unix-2.0' not found
Package 'webkit2gtk-4.0' not found
Package 'gtk+-3.0' not found
Package 'webkit2gtk-4.0' not found
[root@35a7d0a929ba wails_test]#

To Reproduce

  1. Pull the fedora:42 image: docker pull fedora:42
  2. Start the container: docker run -d -it --name wails_test fedora:42 /bin/bash
  3. Enter the container: docker exec -it wails_test /bin/bash
  4. Install Nodejs: curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash and nvm install 22
  5. Install golang: wget https://go.dev/dl/go1.23.4.linux-amd64.tar.gz and tar -C /usr/local -xzf go1.23.4.linux-amd64.tar.gz && export PATH=$PATH:/usr/local/go/bin
  6. Install wails: go install github.com/wailsapp/wails/v2/cmd/wails@latest && export PATH=$PATH:/root/go/bin
  7. Then, initialize a wails demo and run wails doctor and wails build

Expected behaviour

Wails Doctor can detect the environment correctly

Screenshots

No response

Attempted Fixes

No response

System Details

fedora 41 virtual machine:

root@localhost-live:~# wails doctor

                                
          Wails Doctor          
                                

                                                                                                                                                                                
# Wails
Version         | v2.9.2
Package Manager | dnf   

# System
┌──────────────────────────────────────────────────────┐
| OS           | Fedora Linux                          |
| Version      | 41                                    |
| ID           | fedora                                |
| Go Version   | go1.23.4                              |
| Platform     | linux                                 |
| Architecture | amd64                                 |
| CPU          | QEMU Virtual CPU version 2.5+         |
| GPU          | unknown (unknown) - Driver: bochs-drm |
| Memory       | 16GB                                  |
└──────────────────────────────────────────────────────┘

# Dependencies
┌────────────────────────────────────────────────────────┐
| Dependency | Package Name        | Status    | Version |
| *docker    | moby-engine         | Installed | 27.3.1  |
| gcc        | gcc-c++             | Installed | 14.2.1  |
| libgtk-3   | gtk3-devel          | Installed | 3.24.43 |
| libwebkit  | webkit2gtk4.0-devel | Installed | 2.46.3  |
| npm        | nodejs-npm          | Installed | 10.9.0  |
| pkg-config | pkgconf-pkg-config  | Installed | 2.3.0   |
| *upx       | upx                 | Installed | 4.2.4   |
└─────────────── * - Optional Dependency ────────────────┘

# Diagnosis
 SUCCESS  Your system is ready for Wails development!

 ♥   If Wails is useful to you or your company, please consider sponsoring the project:
https://github.com/sponsors/leaanthony
root@localhost-live:~#



fedora:42 docker container:
```bash
[root@35a7d0a929ba wails_test]# wails doctor

                                
          Wails Doctor          
                                

                                                                                                                                                                                
# Wails
Version         | v2.9.2
Package Manager | dnf   

# System
┌────────────────────────────────────────────────┐
| OS           | Fedora Linux                    |
| Version      | 41                              |
| ID           | fedora                          |
| Go Version   | go1.23.4                        |
| Platform     | linux                           |
| Architecture | amd64                           |
| CPU          | AMD EPYC 7763 64-Core Processor |
| Memory       | 32GB                            |
└────────────────────────────────────────────────┘

# Dependencies
┌────────────────────────────────────────────────────────┐
| Dependency | Package Name        | Status    | Version |
| *docker    | moby-engine         | Installed | 27.3.1  |
| gcc        | gcc-c++             | Installed | 14.2.1  |
| libgtk-3   | gtk3-devel          | Installed | 3.24.43 |
| libwebkit  | webkit2gtk4.0-devel | Installed | 2.46.3  |
| npm        | nodejs-npm          | Installed | 10.9.0  |
| pkg-config | pkgconf-pkg-config  | Installed | 2.3.0   |
| *upx       | upx                 | Installed | 4.2.4   |
└─────────────── * - Optional Dependency ────────────────┘

# Diagnosis
 SUCCESS  Your system is ready for Wails development!

 ♥   If Wails is useful to you or your company, please consider sponsoring the project:
https://github.com/sponsors/leaanthony


### Additional context

_No response_
@inlann inlann added the Bug Something isn't working label Jan 15, 2025
@leaanthony
Copy link
Member

It looks like wails doctor does detect them correctly and shows you the version. It looks like there's an environmental issue where pkg-config doesn't detect them?

pkg-config --cflags  -- gtk+-3.0 gio-unix-2.0 webkit2gtk-4.0 gtk+-3.0 gio-unix-2.0 webkit2gtk-4.0 gtk+-3.0 webkit2gtk-4.0
Package gtk+-3.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gtk+-3.0.pc'
to the PKG_CONFIG_PATH environment variable

@inlann
Copy link
Author

inlann commented Jan 17, 2025

It looks like wails doctor does detect them correctly and shows you the version. It looks like there's an environmental issue where pkg-config doesn't detect them?

pkg-config --cflags  -- gtk+-3.0 gio-unix-2.0 webkit2gtk-4.0 gtk+-3.0 gio-unix-2.0 webkit2gtk-4.0 gtk+-3.0 webkit2gtk-4.0
Package gtk+-3.0 was not found in the pkg-config search path.
Perhaps you should add the directory containing `gtk+-3.0.pc'
to the PKG_CONFIG_PATH environment variable

The status of GCC shows as "installed" when running wails doctor even though GCC is not installed.

@leaanthony
Copy link
Member

leaanthony commented Jan 17, 2025

Your bug report is that wails doctor can't detect the packages and it clearly shows it does.

Are you trying to say that gcc-c++ is not the right package for Fedora because it looks like it is? Doesn't that pull in the gcc binary?

https://packages.fedoraproject.org/pkgs/gcc/gcc-c++/index.html

@leaanthony leaanthony added External Issue Not a Wails issue but something wrong with an external dependency and removed Bug Something isn't working labels Jan 17, 2025
@inlann
Copy link
Author

inlann commented Jan 17, 2025

Hmmmm, you mean the dependencies list is generated based on the detection results and differences, right? I thought it was a fixed list, but it actually shows different Status fields depending on the system's installation state.

# Dependencies
┌────────────────────────────────────────────────────────┐
| Dependency | Package Name        | Status    | Version |
| *docker    | moby-engine         | Installed | 27.3.1  |
| gcc        | gcc-c++             | Installed | 14.2.1  |
| libgtk-3   | gtk3-devel          | Installed | 3.24.43 |
| libwebkit  | webkit2gtk4.0-devel | Installed | 2.46.3  |
| npm        | nodejs-npm          | Installed | 10.9.0  |
| pkg-config | pkgconf-pkg-config  | Installed | 2.3.0   |
| *upx       | upx                 | Installed | 4.2.4   |
└─────────────── * - Optional Dependency ────────────────┘

Why is the status of GCC shown as "Installed" in a Fedora container when GCC is not actually installed?

@inlann
Copy link
Author

inlann commented Jan 17, 2025

In a new Fedora container, when running wails doctor, the status of GCC is shown as "installed," but when executing wails build, it throws an error saying GCC is missing. This makes the status displayed by wails doctor very confusing to me.

@leaanthony
Copy link
Member

Well the right package is installed. The PATH in the container might not have the gcc bin dir in it. locate gcc or which gcc and check against echo $PATH.

@inlann
Copy link
Author

inlann commented Jan 20, 2025

Well the right package is installed. The PATH in the container might not have the gcc bin dir in it. locate gcc or which gcc and check against echo $PATH.

No, I did not install gcc in the container. you can check the complete log with a new container based on official image fedora:41:

root@containers:~# docker run -d --name wails_test -it fedora:41 /bin/bash
8c7456166c0ae271df73f0435a7a647b8db3bab4a52bd9a1fdb5a0a97c14bd9f
root@containers:~# docker ps | grep wails
8c7456166c0a   fedora:41                    "/bin/bash"              4 seconds ago   Up 4 seconds                                                                           wails_test
root@containers:~# docker exec -it wails_test /bin/bash
[root@8c7456166c0a /]# which gcc
bash: which: command not found
[root@8c7456166c0a /]# gcc
bash: gcc: command not found
[root@8c7456166c0a /]# echo $PATH
/root/.local/bin:/root/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
[root@8c7456166c0a /]# #Install nodejs
[root@8c7456166c0a /]# curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 16563  100 16563    0     0  16118      0  0:00:01  0:00:01 --:--:-- 16127
=> Downloading nvm as script to '/root/.nvm'

=> Appending nvm source string to /root/.bashrc
=> Appending bash_completion source string to /root/.bashrc
=> Close and reopen your terminal to start using nvm or run the following to use it now:

export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"  # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"  # This loads nvm bash_completion
[root@8c7456166c0a /]# nvm
bash: nvm: command not found
[root@8c7456166c0a /]# export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"  # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"  # This loads nvm bash_completion
[root@8c7456166c0a /]# nvm install nodejs
^C
[root@8c7456166c0a /]# nvm install 20
Downloading and installing node v20.18.1...
Downloading https://nodejs.org/dist/v20.18.1/node-v20.18.1-linux-x64.tar.gz...
##################################################################################################################################################################################################### 100.0%
Computing checksum with sha256sum
Checksums matched!
Now using node v20.18.1 (npm v10.8.2)
Creating default alias: default -> 20 (-> v20.18.1 *)
[root@8c7456166c0a /]# exit
exit
root@containers:~# ls go1.23.4.linux-amd64.tar.gz 
go1.23.4.linux-amd64.tar.gz
root@containers:~# docker cp go1.23.4.linux-amd64.tar.gz wails_test:/root
Successfully copied 73.6MB to wails_test:/root
root@containers:~# docker exec -it wails_test /bin/bash
[root@8c7456166c0a /]# ls
afs  bin  boot  dev  etc  home  lib  lib64  media  mnt  opt  proc  root  run  sbin  srv  sys  tmp  usr  var
[root@8c7456166c0a /]# cd /root/
[root@8c7456166c0a ~]# ls
go1.23.4.linux-amd64.tar.gz
[root@8c7456166c0a ~]# # Install go
[root@8c7456166c0a ~]# tar -C /usr/local -xzf go1.23.4.linux-amd64.tar.gz && export PATH=$PATH:/usr/local/go/bin
[root@8c7456166c0a ~]# go version
go version go1.23.4 linux/amd64
[root@8c7456166c0a ~]# go install github.com/wailsapp/wails/v2/cmd/wails@latest && export PATH=$PATH:/root/go/bin
go: downloading github.com/wailsapp/wails v1.16.9
go: downloading github.com/wailsapp/wails/v2 v2.9.2
go: downloading github.com/flytam/filenamify v1.0.0
go: downloading github.com/leaanthony/debme v1.2.1
go: downloading github.com/leaanthony/clir v1.3.0
go: downloading github.com/leaanthony/gosod v1.0.3
go: downloading github.com/labstack/gommon v0.4.0
go: downloading github.com/jaypipes/ghw v0.12.0
go: downloading github.com/leaanthony/slicer v1.6.0
go: downloading github.com/pkg/errors v0.9.1
go: downloading github.com/pterm/pterm v0.12.49
go: downloading github.com/tidwall/sjson v1.1.7
go: downloading github.com/mattn/go-colorable v0.1.13
go: downloading github.com/mattn/go-isatty v0.0.19
go: downloading github.com/samber/lo v1.38.1
go: downloading github.com/acarl005/stripansi v0.0.0-20180116102854-5a71ef0e047d
go: downloading github.com/fsnotify/fsnotify v1.4.9
go: downloading github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510
go: downloading github.com/pkg/browser v0.0.0-20210911075715-681adbf594b8
go: downloading github.com/sabhiram/go-gitignore v0.0.0-20210923224102-525f6e181f06
go: downloading golang.org/x/mod v0.14.0
go: downloading golang.org/x/sys v0.20.0
go: downloading github.com/wzshiming/ctc v1.2.3
go: downloading github.com/Masterminds/semver v1.5.0
go: downloading github.com/charmbracelet/glamour v0.5.0
go: downloading github.com/jackmordaunt/icns v1.0.0
go: downloading github.com/leaanthony/winicon v1.0.0
go: downloading github.com/tc-hib/winres v0.2.1
go: downloading github.com/go-git/go-git/v5 v5.11.0
go: downloading github.com/tidwall/gjson v1.9.3
go: downloading golang.org/x/exp v0.0.0-20230522175609-2e198f4a06a1
go: downloading atomicgo.dev/cursor v0.1.1
go: downloading atomicgo.dev/keyboard v0.2.8
go: downloading github.com/gookit/color v1.5.2
go: downloading github.com/lithammer/fuzzysearch v1.1.5
go: downloading github.com/mattn/go-runewidth v0.0.13
go: downloading golang.org/x/term v0.20.0
go: downloading golang.org/x/text v0.15.0
go: downloading golang.org/x/tools v0.17.0
go: downloading github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646
go: downloading github.com/wzshiming/winseq v0.0.0-20200112104235-db357dc107ae
go: downloading github.com/ghodss/yaml v1.0.0
go: downloading github.com/jaypipes/pcidb v1.0.0
go: downloading github.com/muesli/termenv v0.9.0
go: downloading github.com/yuin/goldmark v1.4.13
go: downloading github.com/yuin/goldmark-emoji v1.0.1
go: downloading golang.org/x/image v0.12.0
go: downloading github.com/tidwall/match v1.1.1
go: downloading github.com/tidwall/pretty v1.2.0
go: downloading dario.cat/mergo v1.0.0
go: downloading github.com/ProtonMail/go-crypto v0.0.0-20230828082145-3c4c8a2d2371
go: downloading github.com/go-git/go-billy/v5 v5.5.0
go: downloading github.com/sergi/go-diff v1.2.0
go: downloading github.com/containerd/console v1.0.3
go: downloading github.com/xo/terminfo v0.0.0-20210125001918-ca9a967f8778
go: downloading github.com/rivo/uniseg v0.4.4
go: downloading github.com/alecthomas/chroma v0.10.0
go: downloading github.com/microcosm-cc/bluemonday v1.0.17
go: downloading github.com/muesli/reflow v0.3.0
go: downloading github.com/olekukonko/tablewriter v0.0.5
go: downloading gopkg.in/yaml.v2 v2.4.0
go: downloading github.com/mitchellh/go-homedir v1.1.0
go: downloading github.com/lucasb-eyer/go-colorful v1.2.0
go: downloading github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376
go: downloading github.com/pjbgf/sha1cd v0.3.0
go: downloading github.com/emirpasic/gods v1.18.1
go: downloading github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99
go: downloading github.com/cyphar/filepath-securejoin v0.2.4
go: downloading golang.org/x/crypto v0.23.0
go: downloading github.com/aymerick/douceur v0.2.0
go: downloading golang.org/x/net v0.25.0
go: downloading github.com/dlclark/regexp2 v1.4.0
go: downloading github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da
go: downloading github.com/kevinburke/ssh_config v1.2.0
go: downloading github.com/skeema/knownhosts v1.2.1
go: downloading github.com/xanzy/ssh-agent v0.3.3
go: downloading github.com/cloudflare/circl v1.3.7
go: downloading gopkg.in/warnings.v0 v0.1.2
go: downloading github.com/gorilla/css v1.0.0
[root@8c7456166c0a ~]# wails doctor

                                
          Wails Doctor          
                                

                                                                                                                                                                                                            
# Wails
Version         | v2.9.2
Package Manager | dnf   

# System
┌────────────────────────────────────────────────┐
| OS           | Fedora Linux                    |
| Version      | 41                              |
| ID           | fedora                          |
| Go Version   | go1.23.4                        |
| Platform     | linux                           |
| Architecture | amd64                           |
| CPU          | AMD EPYC 7763 64-Core Processor |
| Memory       | 32GB                            |
└────────────────────────────────────────────────┘

# Dependencies
┌────────────────────────────────────────────────────────┐
| Dependency | Package Name        | Status    | Version |
| *docker    | moby-engine         | Installed | 27.3.1  |
| gcc        | gcc-c++             | Installed | 14.2.1  |
| libgtk-3   | gtk3-devel          | Installed | 3.24.43 |
| libwebkit  | webkit2gtk4.0-devel | Installed | 2.46.3  |
| npm        | nodejs-npm          | Installed | 10.9.0  |
| pkg-config | pkgconf-pkg-config  | Installed | 2.3.0   |
| *upx       | upx                 | Installed | 4.2.4   |
└─────────────── * - Optional Dependency ────────────────┘

# Diagnosis
 SUCCESS  Your system is ready for Wails development!

 ♥   If Wails is useful to you or your company, please consider sponsoring the project:
https://github.com/sponsors/leaanthony
[root@8c7456166c0a ~]# dpkg -l | grep gcc
bash: dpkg: command not found
[root@8c7456166c0a ~]# gcc
bash: gcc: command not found
[root@8c7456166c0a ~]# g++
bash: g++: command not found
[root@8c7456166c0a ~]# echo $PATH
/root/.nvm/versions/node/v20.18.1/bin:/root/.local/bin:/root/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/go/bin:/root/go/bin

There is no gcc installation in the container but wails doctor shows the status of gcc is Installed.

@leaanthony
Copy link
Member

I'm not sure how much more help I can be on this. Wails Doctor just reflects what your package manager reports. It runs:

dnf info installed <packagename> which for gcc is dnf info installed gcc-c++

Perhaps try running that in a new container using the exact same docker command. It might be detecting it from the host. Either way, I think the doctor command is doing its job correctly and there's no bug here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
External Issue Not a Wails issue but something wrong with an external dependency
Projects
None yet
Development

No branches or pull requests

2 participants