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. iOS builds ignoring PRE_TARGETDEPS and QMAKE_EXTRA_TARGETS
Forum Updated to NodeBB v4.3 + New Features

iOS builds ignoring PRE_TARGETDEPS and QMAKE_EXTRA_TARGETS

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
2 Posts 1 Posters 330 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.
  • M Offline
    M Offline
    mooglus
    wrote on last edited by mooglus
    #1

    I need to compile another team's c code as a library. I have this working for Windows, Mac and Android, but my iOS build seems to ignore the PRE_TARGETDEPS variable. Essentially I have the following in my .pro file, but the mydep.commands = line never executes, even if I change it to mydep.commands = echo Hello.

    ios {
     QMAKE_EXTRA_TARGETS += mydep
     PRE_TARGETDEPS += mydep
     mydep.commands = make myioslib -C $$PWD/libs/mylib
    
     HEADERS += $$PWD/libs/mylib/libmylib.h
     LIBS += -L$$PWD/libs/mylib/ -lmylib
    }
    

    LIBS += gets seen, because the build then fails during linking

    I'm using Qt 5.12.1

    Is there anything special I need to do for iOS?

    Thanks for any help

    1 Reply Last reply
    0
    • M Offline
      M Offline
      mooglus
      wrote on last edited by mooglus
      #2

      Current workaround is...

      ios {
        system("make myioslib -C $$PWD/libs/mylib")
        HEADERS += $$PWD/libs/mylib/libmylib.h
        LIBS += -L$$PWD/libs/mylib/ -lmylib
      }
      
      1 Reply Last reply
      0

      • Login

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