FyshOS / fynedesk

A full desktop environment for Linux/Unix using Fyne
https://fyne.io/fynedesk/
Other
1.02k stars 47 forks source link

On FreeBSD /usr/include/sys/_lock.h:38:2: error: unknown type name 'u_int' #212

Closed ericbsd closed 3 years ago

ericbsd commented 3 years ago

here is the full error

> go get fyne.io/fynedesk/cmd/fynedesk
go get: installing executables with 'go get' in module mode is deprecated.
    Use 'go install pkg@version' instead.
    For more information, see https://golang.org/doc/go-get-install-deprecation
    or run 'go help get' or 'go help install'.
# github.com/go-gl/glfw/v3.3/glfw
In file included from go/pkg/mod/github.com/go-gl/glfw/v3.3/glfw@v0.0.0-20200625191551-73d3c3675aa3/native_linbsd.go:10:
In file included from go/pkg/mod/github.com/go-gl/glfw/v3.3/glfw@v0.0.0-20200625191551-73d3c3675aa3/glfw/include/GLFW/glfw3native.h:114:
In file included from /usr/local/include/GL/glx.h:32:
/usr/local/include/GL/gl.h:56:11: warning: 'GLAPIENTRY' macro redefined [-Wmacro-redefined]
go/pkg/mod/github.com/go-gl/glfw/v3.3/glfw@v0.0.0-20200625191551-73d3c3675aa3/glfw/include/GLFW/glfw3.h:5863:10: note: previous definition is here
# github.com/godbus/dbus/v5
In file included from go/pkg/mod/github.com/godbus/dbus/v5@v5.0.4-0.20200513180336-df5ef3eb7cca/transport_unixcred_freebsd.go:13:
In file included from /usr/include/sys/ucred.h:39:
/usr/include/sys/_lock.h:38:2: error: unknown type name 'u_int'
        u_int   lo_flags;
        ^
/usr/include/sys/_lock.h:39:2: error: unknown type name 'u_int'
        u_int   lo_data;                /* General class specific data. */
        ^
In file included from go/pkg/mod/github.com/godbus/dbus/v5@v5.0.4-0.20200513180336-df5ef3eb7cca/transport_unixcred_freebsd.go:13:
In file included from /usr/include/sys/ucred.h:40:
/usr/include/sys/_mutex.h:49:11: error: unknown type name 'uintptr_t'
        volatile uintptr_t      mtx_lock;       /* Owner and flags. */
                 ^
/usr/include/sys/_mutex.h:63:11: error: unknown type name 'uintptr_t'
        volatile uintptr_t      mtx_lock;       /* Owner and flags. */
                 ^
4 errors generated.
Jacalz commented 3 years ago

I know that this was a known issue with the godbus project on FreeBSD 13. I think this might be fixed on the develop branch. Would you mind trying that branch instead?

ericbsd commented 3 years ago

Yes, I can., How do I proceed to install from the development branch?

Jacalz commented 3 years ago

It is probably easiest to just do go install fyne.io/fynedesk/cmd/fynedesk@develop. It can also be done by cloning the repo, doing git checkout develop and lastly running make && sudo make install.

ericbsd commented 3 years ago
ericbsd@ericbsed-ghostbsd-pc /u/h/e/fynedesk (develop)> make && sudo make install
go build ./cmd/fynedesk_runner
go: downloading fyne.io/fyne/v2 v2.1.0
go build ./cmd/fynedesk
go: downloading github.com/fyne-io/xgbutil v0.0.0-20191220152344-7d838166824d
go: downloading github.com/godbus/dbus/v5 v5.0.4
go: downloading golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c
go: downloading github.com/yuin/goldmark v1.3.8
go: downloading github.com/go-gl/glfw/v3.3/glfw v0.0.0-20210410170116-ea3d685f79fb
go: downloading github.com/srwiley/oksvg v0.0.0-20210519022825-9fc0c575d5fe
go: downloading golang.org/x/image v0.0.0-20210628002857-a66eb6448b8d
go: downloading github.com/go-gl/gl v0.0.0-20210905235341-f7a045908259
go: downloading golang.org/x/net v0.0.0-20210917221730-978cfadd31cf
go: downloading golang.org/x/text v0.3.7
# fyne.io/fynedesk/modules/status
modules/status/sound_bsd.go:56:15: invalid operation: vol + ":" (mismatched types int and untyped string)
# github.com/go-gl/glfw/v3.3/glfw
In file included from /home/ericbsd/go/pkg/mod/github.com/go-gl/glfw/v3.3/glfw@v0.0.0-20210410170116-ea3d685f79fb/native_linbsd.go:10:
In file included from /home/ericbsd/go/pkg/mod/github.com/go-gl/glfw/v3.3/glfw@v0.0.0-20210410170116-ea3d685f79fb/glfw/include/GLFW/glfw3native.h:114:
In file included from /usr/local/include/GL/glx.h:32:
/usr/local/include/GL/gl.h:56:11: warning: 'GLAPIENTRY' macro redefined [-Wmacro-redefined]
/home/ericbsd/go/pkg/mod/github.com/go-gl/glfw/v3.3/glfw@v0.0.0-20210410170116-ea3d685f79fb/glfw/include/GLFW/glfw3.h:5894:10: note: previous definition is here
*** Error code 2
Jacalz commented 3 years ago

Oh no. That looks like a build failure on our side instead. I'll try to have a look later today hopefully.

Jacalz commented 3 years ago

Sorry for introducing that silly issue in the first place. I now have #213 open with a fix for the compilation failure.

Jacalz commented 3 years ago

That PR is merged now. Feel free to give it another test when you can :)

ericbsd commented 3 years ago

Sorry for introducing that silly issue in the first place. I now have #213 open with a fix for the compilation failure.

No worry I do that often.

ericbsd commented 3 years ago

Looks good so far.

go build ./cmd/fynedesk_runner
go build ./cmd/fynedesk
# github.com/go-gl/glfw/v3.3/glfw
In file included from /home/ericbsd/go/pkg/mod/github.com/go-gl/glfw/v3.3/glfw@v0.0.0-20210410170116-ea3d685f79fb/native_linbsd.go:10:
In file included from /home/ericbsd/go/pkg/mod/github.com/go-gl/glfw/v3.3/glfw@v0.0.0-20210410170116-ea3d685f79fb/glfw/include/GLFW/glfw3native.h:114:
In file included from /usr/local/include/GL/glx.h:32:
/usr/local/include/GL/gl.h:56:11: warning: 'GLAPIENTRY' macro redefined [-Wmacro-redefined]
/home/ericbsd/go/pkg/mod/github.com/go-gl/glfw/v3.3/glfw@v0.0.0-20210410170116-ea3d685f79fb/glfw/include/GLFW/glfw3.h:5894:10: note: previous definition is here
Password:
install -Dm00755 fynedesk_runner /usr/local/bin/fynedesk_runner
install -Dm00755 fynedesk /usr/local/bin/fynedesk
install -Dm00644 fynedesk.desktop /usr/local/share/xsessions/fynedesk.desktop
ericbsd commented 3 years ago

It is working. Here is a screenshot. screenshot-20211017T130040

I am closing this issue.

ericbsd commented 3 years ago

If the sidebar could be on the left that would be perfect.

andydotxyz commented 3 years ago

If the sidebar could be on the left that would be perfect.

Nice idea for a user setting, please open a feature request (or post a PR ;) )

Jacalz commented 3 years ago

Nice to hear that it's working now. I think we are planning for a new release relatively soon-ish :)