Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Use my own platform plugin (lighthouse)

Use my own platform plugin (lighthouse)

Scheduled Pinned Locked Moved Mobile and Embedded
4 Posts 2 Posters 4.1k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    billconan
    wrote on 1 Jun 2011, 19:00 last edited by
    #1

    Hello guys,

    I want to experiment my own lighthouse plugin. But once I have it, how should I compile QT and let it know that I want to use my own lighthouse plugin?

    are these defined under mkspecs? or how should I configure the QT project? any document for this?

    Thanks.

    1 Reply Last reply
    0
    • C Offline
      C Offline
      CuteiOS
      wrote on 3 Jun 2011, 11:30 last edited by
      #2

      Hi,

      You build Qt for your platform (you'll need to make your own mkspec for your platform) and then build your plugin.

      The mkspec tells Qt things like which (cross)compiler to use, and any other specifics (like header paths, compiler arguments etc.) you might need for your platform. Currently, QPA builds use mkspecs in the mkspecs/qws folder, but there's nothing stopping you from putting your's where it makes sense (I put mine in mkspecs/qpa).

      To use your plugin, you need to use the -platform argument to your Qt app executable eg.:

      animatedtiles -platform minimal

      It's a good idea to start with the minimal plugin, as that will build for all platforms and is a good way to make sure you have the other portions of the build process working.

      Good Luck!

      Lighthouse support is done via the #qt-lighthouse IRC channel on freenode...

      1 Reply Last reply
      0
      • B Offline
        B Offline
        billconan
        wrote on 3 Jun 2011, 17:55 last edited by
        #3

        This is very useful information, Thank you very much!

        yesterday, I figure out that, which platform plugin to use is determined during the runtime, by a function called
        qt_guiPlatformPlugin() defined under qguiplatformplugin.cpp
        inside the function, QT checks an environment variable QT_PLATFORM_PLUGIN, and decides which plugin to load.

        I have one further question, is there any document for writing a mkspec?

        Thank you so much!

        1 Reply Last reply
        0
        • C Offline
          C Offline
          CuteiOS
          wrote on 3 Jun 2011, 18:48 last edited by
          #4

          There are actually 3 ways to specify the plugin, the two mentioned above, and by setting the QT_QPA_DEFAULT_PLATFORM_NAME #define in your platform's qplatformdefs.h file.

          There may or may not be a document for mkspec creation (I would expect so), but the easiest way is to find the platform most similar to your's and use that mkspec as a basis...

          1 Reply Last reply
          0

          1/4

          1 Jun 2011, 19:00

          • Login

          • Login or register to search.
          1 out of 4
          • First post
            1/4
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved