wangbjun / catya

一个100%使用Go开发的开源的虎牙直播桌面客户端应用
Apache License 2.0
111 stars 33 forks source link

compilation terminated #1

Closed kybom closed 3 years ago

kybom commented 3 years ago
sma@ubuntu:~/work/catya-1.0$ ls
build.sh  go.mod  go.sum  huya  logo.png  main.go  README.md  theme
sma@ubuntu:~/work/catya-1.0$ ./build.sh
go: downloading fyne.io/fyne v1.4.3
go: downloading github.com/tidwall/gjson v1.8.1
go: downloading github.com/tidwall/match v1.0.3
go: downloading github.com/tidwall/pretty v1.1.0
go: downloading fyne.io/fyne/v2 v2.0.3
go: downloading github.com/fsnotify/fsnotify v1.4.9
go: downloading github.com/godbus/dbus/v5 v5.0.4
go: downloading github.com/go-gl/glfw/v3.3/glfw v0.0.0-20210410170116-ea3d685f79fb
go: downloading github.com/go-gl/gl v0.0.0-20190320180904-bf2b1f2f34d7
go: downloading github.com/goki/freetype v0.0.0-20181231101311-fa8a33aabaff
go: downloading github.com/srwiley/oksvg v0.0.0-20200311192757-870daf9aa564
go: downloading golang.org/x/image v0.0.0-20200430140353-33d19683fad8
go: downloading github.com/srwiley/rasterx v0.0.0-20200120212402-85cb7272f5e9
go: downloading github.com/fredbi/uri v0.0.0-20181227131451-3dcfdacbaaf3
go: downloading golang.org/x/sys v0.0.0-20200720211630-cb9d2d5c5666
go: downloading golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e
go: downloading golang.org/x/text v0.3.2
# pkg-config --cflags  -- gl gl
Package gl was not found in the pkg-config search path.
Perhaps you should add the directory containing `gl.pc'
to the PKG_CONFIG_PATH environment variable
No package 'gl' found
Package gl was not found in the pkg-config search path.
Perhaps you should add the directory containing `gl.pc'
to the PKG_CONFIG_PATH environment variable
No package 'gl' found
pkg-config: exit status 1
# github.com/go-gl/glfw/v3.3/glfw
In file included from ./glfw/src/internal.h:188,
                 from ./glfw/src/context.c:30,
                 from ../../../go/pkg/mod/github.com/go-gl/glfw/v3.3/glfw@v0.0.0-20210410170116-ea3d685f79fb/c_glfw.go:4:
./glfw/src/x11_platform.h:33:10: fatal error: X11/Xlib.h: No such file or directory
   33 | #include <X11/Xlib.h>
      |          ^~~~~~~~~~~~
compilation terminated.
wangbjun commented 3 years ago

你这个出错像是没有安装opengl的库,或者说显卡没有驱动? 我电脑上直接就跑起来了

kybom commented 3 years ago

ubuntu20.04是虚拟机,用的vmare的驱动。 在谷歌上找到了原因 https://github.com/go-gl/glfw/blob/master/README.md

wangbjun commented 3 years ago

ubuntu20.04是虚拟机,用的vmare的驱动。 在谷歌上找到了原因 https://github.com/go-gl/glfw/blob/master/README.md

原来如此,我自己电脑可能以前装过就没出现这个问题