[08:52] hey [08:52] duflu, are you around? [08:53] hikiko: Yes [08:53] hello :) [08:53] do you know anything about miral? === dandrader is now known as dandrader|afk [08:54] I run it and it crashes with this error: [08:54] http://pastebin.com/wzCNkedA [08:54] and I am almost sure, I didn't install some mir or miral dependency [08:55] hikiko: Don't know. Try alan_g (who starts in 5 minutes?) [08:56] ok :) thanks! [08:56] lol here he is! [08:56] hi alan_g [08:56] I have questions for you!! [08:56] good morning :) [08:57] mmm duflu do you use any ppa for mir? [08:58] hikiko: No. Just zesty, or compile lp:mir. But I only use Unity8 with the official zesty packages [08:59] I can't compile mir for some reason either... I get some compile errors [08:59] can I show you? [08:59] hikiko: That's interesting. Yes please show the error [08:59] might be just my configuration :p 1 sec [09:01] duflu, linker* errors [09:02] https://paste.ubuntu.com/24136976/ [09:02] I am pretty sure I didn't install something properly [09:02] I am building that inside a chroot [09:02] so I might miss some package [09:03] I have installed mir common, platform, client, server, mesa-x12 etc [09:06] hikiko: are you following https://unity.ubuntu.com/mir/0.26/building_source_for_pc.html? [09:06] alan_g, yes [09:07] also miral-shell gives me a segfault because some cpp is missing give me a sec [09:07] [10:54:00] <hikiko> I run it and it crashes with this error: [09:07] [10:54:20] <hikiko> http://pastebin.com/wzCNkedA [09:07] alan_g, I am sure there's something on my system missing because I could run miral [09:07] but I can't figure out what [09:08] hikiko: I don't see how those instructions would try to lonk with //usr/lib/x86_64-linux-gnu/libmirclient.so.9 [09:08] *kink [09:08] **link [09:08] alan_g, I don't know either [09:08] I just copy pasted all the commands [09:08] oh I don't know if it's relevant [09:08] I am using also this ppa: [09:09] hikiko: "./miral-shell/decoration_provider.cpp:196" is trying to load a font [09:09] cemil-azizoglu-ubuntu-mesa-rs-zesty.list [09:10] I am apt-file searching it [09:10] ttf-ubuntu-font-family: /usr/share/fonts/truetype/ubuntu-font-family/Ubuntu-B.ttf [09:10] alan_g, it seems that the font is there [09:11] hikiko: It appears you have an old version of the libmirclient package installed (0.25) but a new libmirclient (0.26). Try updating to ensure they are all version 0.26.1 [09:11] hikiko: It appears you have an old version of the libmirclient package installed (0.25) but a new libmircommon (0.26). Try updating to ensure they are all version 0.26.1 [09:11] hikiko: zesty right? [09:12] duflu, yes [09:12] but apt-get update/dist-upgrade [09:12] doesn't propose anything for mir [09:12] Hmm [09:12] hikiko: dpkg -l | grep libmir [09:13] duflu, http://pastebin.com/UWBS4hHx [09:13] it seems that everything is 0.26 :s [09:13] Oh, maybe I should not expect the symbol versions to change. Hang on [09:20] * alan_g wonders why loading the font failed at L196, not L96 (which gives a clear message) [09:20] alan_g, do you want a backtrace> [09:20] ? [09:21] hikiko: That PPA won't cause the problem either. I guess you have either leftovers from some old PPA or custom environment finding libmircommon in a strange place [09:21] hikiko: does "$ miral-app -kiosk" run? [09:21] I really wish we didn't have launcher commands [09:22] But now count at least four [09:22] alan_g, it gives the same error [09:22] but then: [09:22] waiting for /run/user/1000/mir_socket [09:22] waiting for /run/user/1000/mir_socket [09:22] oh [09:22] sec [09:22] maybe it's the chroot [09:23] * alan_g wonders how it can give an error from code that isn't running [09:23] or even in the executable [09:23] [2017-03-08 09:23:40.909694] mirserver: Using software cursor [09:23] ERROR: Throw location unknown (consider using BOOST_THROW_EXCEPTION) [09:23] Dynamic exception type: boost::exception_detail::clone_impl > [09:23] std::exception::what: bind: No such file or directory [09:23] Segmentation fault [09:23] waiting for /run/user/1000/mir_socket [09:23] waiting for /run/user/1000/mir_socket [09:24] then it prints the message forever [09:24] If the server crashes /run/user/1000/mir_socket will take a long time to appear [09:24] Just kill it with ^C [09:25] yep, I killed it already [09:25] Do you have anything Mir in /usr/local/lib? [09:25] let me check [09:26] no [09:26] just python [09:26] $ ldd `which miral-shell` [09:27] Morning alf_ ... Perhaps interesting reading: https://lists.freedesktop.org/archives/mesa-dev/2014-July/063977.html [09:27] alan_g, http://pastebin.com/zAVKL89W [09:28] (which I only found when searching for the new function he added in the header but failed to implement) [09:30] That all looks sane [09:31] then why it segfaults? [09:33] Not obvious. [09:35] duflu: thanks [09:36] It's annoying to debug too - (mir-on-X grabs input). Can you ssh from a different machine? [09:36] alan_g, it's a chroot I guess if I open it from another terminal it's fine [09:37] it doesnt grub input btw if you roll the window :) [09:41] hikiko: for differential diagnosis - do Mir & MirAL work outside the chroot? [09:41] mmm miral-shell seems to work === dandrader|afk is now known as dandrader [09:42] I don't know about mir I don't want to install its dependencies on desktop [09:43] Sure [09:43] so, it's probably what I suspect [09:43] something missing from chroot [09:43] Yeah [09:43] that is installed on desktop [09:45] A stacktrace from miral-kiosk might give a clue [09:45] There's clearly also a problem with the font [09:47] It may not be relevant now, but when I first did font support I found I could not use the Ubuntu font because it was missing in Core [09:47] interesting: miral-kiosk without params can run (it shows a red screen that fades out) when I mount /run/user/1000 [09:47] but miral-shell cant [09:48] alan_g, the font is just a warning [09:48] I think the real error is that: [09:48] (anonymous namespace)::Printer::printhelp ( [09:48] this=0x55555583a080 <(anonymous namespace)::render_pattern(MirGraphicsRegion*, unsigned char const*)::printer>, region=...) [09:48] at ./miral-shell/decoration_provider.cpp:196 [09:48] 196 ./miral-shell/decoration_provider.cpp: No such file or directory. [09:50] $ apt-file search decoration_provider.cpp returns nothing [09:50] that's why I was wondering if my mir version is outdated and I need a ppa [09:51] hikiko: ./miral-shell/decoration_provider.cpp:196 is trying to use the font. Are you sure it exists with sane access permissions in the chroot? [09:52] If you're using Core/snappy then it's possible the Ubuntu font doesn't exist still. That's why I used LiberationSans-Bold.ttf. Confusingly Ubuntu Core did contain RedHat's font [09:53] hikiko: Are you running full desktop zesty? [09:54] Might have a similar problem with Ubuntu Server [09:55] OK, if miral-kiosk runs then the only problem seems to be the font [09:55] Are there any fonts in the chroot? [09:55] I reinstalled the font [09:55] and worked :) [09:55] now I have to find out why mir doesn't build, I guess something similar :p [09:55] alan_g, yes [09:56] there were [09:56] hikiko: What ISO did you install from? [09:56] If any [09:56] duflu, no iso I used debootstrap [09:56] on zesty [09:56] You can choose the font with --shell-titlebar-font [09:57] I guess a more elegant fallback than crashing is required for missing fonts [09:57] yeah :) [09:58] anyway, thanks duflu alan_g :) [09:58] duflu: it's odd - it exits with an error if opening the font fails. This is something new. [09:58] Oh [09:58] Anyone found PosixRWMutex unit tests hang/fail? [09:58] I'm only seeing it today [09:59] Hmm. I was wrong... [09:59] WARNING: failed to load titlebar font: "rubbish" [09:59] Segmentation fault (core dumped) [10:02] That's not this one is it? https://errors.ubuntu.com/problem/c4a91485a9e7bf2774806d21e8c6c71f8ef79f08 [10:02] hikiko: do you see a "WARNING: failed to load titlebar font" message before the segfault? [10:05] yes alan_g [10:05] * alan_g goes to log a bug [10:06] but as I said, after re-installing ubuntu fonts I don't see the segfault, it works great [10:06] Sure, but it shouldn't segfault if the font isn't there. [10:07] duflu: I can't tell what that is [10:33] greyback: HTH https://bugs.launchpad.net/miral/+bug/1670741/comments/1 [10:33] Ubuntu bug 1670741 in MirAL "Have a MIRAL_WINDOW_MANAGEMENT_TRACE env var" [Undecided,Invalid] [10:34] alan_g: oh so that already works? Great [10:34] You just had the spellign wrong [10:35] *nod* understood [10:35] * alan_g can't type this morning [11:45] alan_g: https://bugs.launchpad.net/miral/+bug/1670876 <- ack, I couldn't see any real miral code that would impact it, but logged it against miral as miral-shell has the same bug [11:45] Ubuntu bug 1670876 in Mir "Setting cursor causes window's input_region to be reset" [Undecided,New] [11:46] Sure, it's either the new APIs or misuse of the new APIs === dandrader is now known as dandrader|afk === dandrader|afk is now known as dandrader [15:50] is gtk supposed to be receiving a resize event when the window appears? or should gtk be querying this manually? [15:55] attente: the resize events are mostly useless as they are not synced with the size of the buffer. The buffer has a size which is accurate. [15:57] alan_g: but the resize events are still useful for checking when the buffer size changes, no? [15:58] attente: well, if the size doesn't match the buffer, then there is a possibility that you'll get a buffer of a different size after a few swaps. (Unless there's another resize first) [15:58] Not sure how useful that is though. [15:59] alan_g: ok, so the buffer size is authoritative basically... [15:59] alan_g: thanks [16:02] this is a bit annoying that we have to keep track of the size and synthesize the gdk event when it changes, but should be manageable [16:05] kdub: ^^ anything to add for NBS? === dandrader is now known as dandrader|afk [16:49] attente: I can say from the Qt side, we totally ignore the mir resize event. It arrives at an arbitrary time. It would be far more useful if it arrived, and then you were guaranteed the next buffer you swap has that size. [16:49] we go by the buffer size instead [16:49] which is not ideal [16:50] greyback: ok, thanks for the info. in the end i don't see it being too much of a problem [16:51] * alan_g thinks we should never have provided resize events. Then people wouldn't try to use them. [17:00] * attente shrugs [17:01] I see value in resize events, but only if they arrive at the right time [17:01] if this is the concern, why not deprecate them? [17:02] oh, resize events make sense now [17:03] they're a notification that the shell has redesignated the size, and the client is in control of the physical size of the buffers [17:03] and lets the client figure out how its subscene should get resized [17:05] kdub: what if the client decides to set the buffer size to something different from the resize event's size? [17:05] kdub: what if client creates buffers of sizes that the shell didn't decide on? [17:05] heh, same question, different epxression [17:05] :) [17:06] only real buffer management qtubuntu is doing is via egl swap buffers [17:07] a different physical buffer size isn't a problem, the client arranges its scene via mir_window_spec_set_streams [17:07] and the difference is accommodated by the renderer, usually scaling, but guess a renderer could also do clamping or whatever if it wanted [17:08] greyback, the new system, when the resize event comes along, its only an indication that the shell has resized the on-screen size [17:09] but that kind of invalidates the approach we were talking about earlier where we would check the buffer size to reliably determine the window size [17:09] and the client calls mir_render_surface_set_physical_size() (soon to be mir_surface_set_physical_size()), and at that point, then the next buffer out of eglSwapBuffers will be the right size [17:09] so it is up to shell to confine any client buffers that "mis-behave" [17:09] well, the shell is already painting at the size it wants [17:10] i'm really just looking for a reliable way to know the size we should render at to get no scaling [17:10] sure. But as I understood it, clients got a buffer of size whose size the shell decided ultimately [17:10] in the new system, the clients are in charge of buffers [17:10] this is what i thought too, greyback [17:11] based on what alan_g was saying [17:11] so, in the case where there are no sub-surfaces (one surface to one bufferstream) [17:11] kdub: ok, new system behaves differently, that's ok. I just wanted to be consider the diffference from the shell's PoV [17:11] kdub: so does that mean this bug should theoretically fix itself once the new system is in place? https://bugs.launchpad.net/ubuntu/+source/gtk+3.0/+bug/1670390 [17:12] Ubuntu bug 1670390 in unity8 (Ubuntu) "Desktop applications don't get properly resized when launched in staged mode" [High,In progress] [17:12] (speaking from a gtk perspective) [17:12] attente: that's unity8 only, right? [17:13] greyback: i'm not sure. but i haven't seen this bug in miral-shell [17:13] attente: if not in miral-shell, then probably unity8's fault [17:13] re the bug, not sure without thinking harder [17:13] greyback: i'm just confused about how to reliably get the window size [17:13] attente: I'd go with buffer size for now [17:13] attente, which window size? :) [17:14] kdub: the mir window size :) [17:14] attente: there is a general problem with unity8 and window resizing, which I think is mainly qtmir's fault (for which I've ideas) [17:14] kdub: like, should i be expecting it to come from a resize event? or do i have to query it? [17:14] sure, the size of the window that the shell designates is comes from the resize callback [17:14] right, resize event, no querying [17:15] kdub: ok, then there's definitely an issue with unity8 not sending the proper resize event when the window appears [17:15] or in stage mode for that matter [17:15] attente, iirc, there's no resize event sent at startup [17:16] attente: here is how we're doing it in Qt: http://bazaar.launchpad.net/~phablet-team/qtubuntu/trunk/view/head:/src/ubuntumirclient/qmirclientwindow.cpp#L641 [17:16] kdub: what's the right thing to do here? query on window creation? or should u8 send a resize event? [17:17] attente: look for "handleGeometryChange" <- that is how we notify Qt of the window size change [17:18] greyback: is it worth doing this if the new system is supposed to send resize events reliably at some point? [17:18] attente: I can't answer that, sorry. I can only tell you what works for us now [17:19] greyback: fair enough, thanks for the pointers. i think i'll eventually just copy what you've already done [17:20] i think mir_window_get_parameters at startup to get the initial size the shell said, and after that the callback or you can requery via that function [17:21] yep, we do that in qtubuntu, works ok === dandrader|afk is now known as dandrader [17:24] right, in the old system, server/shell controlled both window size and physical size, in the new system, the server controls window size, and the client controls/owns the physical buffers (and their sizes) [17:24] gotcha [17:24] kdub: will old system hang around? Or eventually deprecated? [17:25] kdub: and roughly on the topic, what about pixel format. If every buffer can have different pixel format, why would Window have that property (ref: https://bugs.launchpad.net/mir/+bug/1666533/comments/9) [17:25] Ubuntu bug 1666533 in MirAL "Shell wants api to listen for window pixel_format changes" [Medium,Incomplete] [17:27] greyback, the old system really only exists in the client api that's being deprecated (internally, things are already plumbed with client-controlled physical sizes) [17:28] greyback, windows no longer have pixel format [17:28] hmm, might be a missed deprecation there [17:28] i guess it says 'to be deprecated soon' in the comments [17:28] ok [17:31] kdub: from unity8's perspective, something that we be really useful is a notification that a client swapped a buffer with the new size & pixel format, as soon as the client swapped it [17:31] s/we/would/ [17:32] welll [17:32] actually, ignore hat [17:32] sure :) [17:32] I need to test an idea first. But if that idea fails, I'll be back to you [17:33] looking at qmirclientwindow.cpp, mir_buffer_stream_get_egl_native_window is going away soon [17:33] kdub: I presume it will get a replacement of similar functionality? [17:34] greyback, right, so in the mir-1.0 world, you just plug a MirSurface (formerly MirRenderSurface) into eglCreateWindowSurface [17:35] the MirSurface->MirWindow and MirRenderSurface->MirSurface rename in 1.0 makes for confusion when talking about it :) [17:36] basically, we've gone from being a server that supports 2 different EGL systems, to being one that has a mir egl platform [17:37] yep, the transition made all my old terminology confused [17:39] yeah, we also need a grand mir-server-internal rename for it :/ === JanC_ is now known as JanC