<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body>
    Hi Emil,<br>
    <br>
    I think you need to adjust your finish-args. Try to explicitly add
    --socket=wayland.<br>
    <br>
    Cheers<br>
    Ondra<br>
    <br>
    <div class="moz-cite-prefix">On 07/02/2021 1:26 pm, Emil Johansson
      wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:CALiNQvUQZ2aaJ5WBsG6Q+0gPEY6ahoMd7p3A9vX_49F+WetyiA@mail.gmail.com">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <div dir="ltr">
        <div>Hey,</div>
        <div><br>
        </div>
        <div>I am trying to make a flatpak version of my command line
          application <a href="https://github.com/emiljoha/mpw"
            target="_blank" moz-do-not-send="true">https://github.com/emiljoha/mpw</a>.
          I have gotten most of the dependencies in order but I have not
          been able to figure out how to write to the clipboard.</div>
        <div><br>
        </div>
        <div>I have managed to bundle wl-clipboard but it says it cannot
          connect to a wayland server. Looking in the source code of
          wl-clipboard it gets NULL back from wl_display_connect. From
          the documentation I can find <a
href="https://manpages.debian.org/experimental/libwayland-doc/wl_display_connect.3.en.html"
            moz-do-not-send="true">https://manpages.debian.org/experimental/libwayland-doc/wl_display_connect.3.en.html</a>
          <br>
        </div>
        <div><br>
        </div>
        <div>> <b>wl_display_connect</b> connects to a Wayland
          socket that was previously opened by a Wayland server. The
          server socket must be placed in <b>XDG_RUNTIME_DIR</b> when <b>WAYLAND_DISPLAY</b>
          (or <i>name</i>, see below) is a simple name, for this
          function to find it. The server socket is also allowed to
          exist at an arbitrary path</div>
        <div><br>
        </div>
        <div>wl-copy.c call the function with NULL as the name.<br>
        </div>
        <div><br>
        </div>
        <div>I have in my manifest.<br>
        </div>
        <div>
          <table class="gmail-diff-table gmail-js-diff-table
            gmail-tab-size">
            <tbody>
              <tr>
                <td class="gmail-blob-code gmail-blob-code-addition"><span
                    class="gmail-blob-code-inner gmail-blob-code-marker"><span
                      class="gmail-pl-ent">finish-args</span>:</span></td>
              </tr>
              <tr>
              </tr>
            </tbody>
          </table>
          <table class="gmail-diff-table gmail-js-diff-table
            gmail-tab-size">
            <tbody>
              <tr>
                <td class="gmail-blob-code gmail-blob-code-addition">  
                  <span class="gmail-blob-code-inner
                    gmail-blob-code-marker"><span class="gmail-pl-s">--socket=fallback-x11</span></span></td>
              </tr>
              <tr>
              </tr>
            </tbody>
          </table>
             <span class="gmail-blob-code-inner gmail-blob-code-marker"><span
              class="gmail-pl-s">--share=ipc</span></span></div>
        <div><span class="gmail-blob-code-inner gmail-blob-code-marker"><span
              class="gmail-pl-s"><br>
            </span></span></div>
        <div>More details and the code of my attempt can be found in the
          PR <a href="https://github.com/emiljoha/mpw/pull/21"
            moz-do-not-send="true">https://github.com/emiljoha/mpw/pull/21</a></div>
        <div><br>
        </div>
        <div>Thanks<br>
        </div>
        <div>Emil<br>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <pre class="moz-quote-pre" wrap="">_______________________________________________
Flatpak mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Flatpak@lists.freedesktop.org">Flatpak@lists.freedesktop.org</a>
<a class="moz-txt-link-freetext" href="https://lists.freedesktop.org/mailman/listinfo/flatpak">https://lists.freedesktop.org/mailman/listinfo/flatpak</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>