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. qmake_use.prf(6) 'take first' is not a recognized replace function
Forum Updated to NodeBB v4.3 + New Features

qmake_use.prf(6) 'take first' is not a recognized replace function

Scheduled Pinned Locked Moved Solved Mobile and Embedded
14 Posts 3 Posters 4.8k Views 1 Watching
  • 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.
  • D dmnc

    I make a cross-complier on ubuntu ,and successfully get a qmake.but when I open a qt creator and create a porject, the "General Messages" console print a project error: /home/damon/qt5/mkspecs/features/qmake_use.prf(6): 'take_first' is not a recongnized replace function.
    Project ERROR: Library " is not defined.
    Anyone have met this error and how to solve it ? thank you very much.

    jsulmJ Offline
    jsulmJ Offline
    jsulm
    Lifetime Qt Champion
    wrote on last edited by
    #3

    @dmnc said in qmake_use.prf(6) 'take first' is not a recognized replace function:

    /home/damon/qt5

    Is this your cross-compiled Qt?
    Did you set-up a Kit with this Qt properly and used it with your project in QtCreator?

    https://forum.qt.io/topic/113070/qt-code-of-conduct

    D 1 Reply Last reply
    0
    • jsulmJ jsulm

      @dmnc said in qmake_use.prf(6) 'take first' is not a recognized replace function:

      /home/damon/qt5

      Is this your cross-compiled Qt?
      Did you set-up a Kit with this Qt properly and used it with your project in QtCreator?

      D Offline
      D Offline
      dmnc
      wrote on last edited by
      #4

      @jsulm I was referenced this tutorial http://wiki.qt.io/RaspberryPi2EGLFS
      and my cross compile command line: ./configure -release -opengl es2 -device linux-rasp-pi3-g++ for RPi3 -device-option CROSS_COMPILE=~/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- -sysroot ~/raspi/sysroot -opensource -confirm-license -make libs -prefix /usr/local/qt5pi -extprefix ~/raspi/qt5pi -hostprefix ~/raspi/qt5 -v -no-use-gold-linker
      I created qt projects with my Kit setting for raspberry pi3B ,qmake and build,everyting is ok ,than I synchronized the executable files to the pi device ,they worked perfectly. but there exists another two problem ,one is the remote deploy function doesn't work,I added the follow codes to the .pro file already :INSTALLS+=target target.path=/home/pi/ ,but the "Files to deploy:"filed show empty,and the "Executable on device:" field show "Remote path not set".the other problem is the project tree in the Project panel shows nothing but a directory.

      jsulmJ 1 Reply Last reply
      0
      • D dmnc

        @jsulm I was referenced this tutorial http://wiki.qt.io/RaspberryPi2EGLFS
        and my cross compile command line: ./configure -release -opengl es2 -device linux-rasp-pi3-g++ for RPi3 -device-option CROSS_COMPILE=~/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- -sysroot ~/raspi/sysroot -opensource -confirm-license -make libs -prefix /usr/local/qt5pi -extprefix ~/raspi/qt5pi -hostprefix ~/raspi/qt5 -v -no-use-gold-linker
        I created qt projects with my Kit setting for raspberry pi3B ,qmake and build,everyting is ok ,than I synchronized the executable files to the pi device ,they worked perfectly. but there exists another two problem ,one is the remote deploy function doesn't work,I added the follow codes to the .pro file already :INSTALLS+=target target.path=/home/pi/ ,but the "Files to deploy:"filed show empty,and the "Executable on device:" field show "Remote path not set".the other problem is the project tree in the Project panel shows nothing but a directory.

        jsulmJ Offline
        jsulmJ Offline
        jsulm
        Lifetime Qt Champion
        wrote on last edited by
        #5

        @dmnc said in qmake_use.prf(6) 'take first' is not a recognized replace function:

        shows nothing but a directory

        Did you run qmake from QtCreator?

        https://forum.qt.io/topic/113070/qt-code-of-conduct

        D 1 Reply Last reply
        0
        • jsulmJ jsulm

          @dmnc said in qmake_use.prf(6) 'take first' is not a recognized replace function:

          shows nothing but a directory

          Did you run qmake from QtCreator?

          D Offline
          D Offline
          dmnc
          wrote on last edited by
          #6

          @jsulm yes I did

          jsulmJ 1 Reply Last reply
          0
          • D dmnc

            @jsulm yes I did

            jsulmJ Offline
            jsulmJ Offline
            jsulm
            Lifetime Qt Champion
            wrote on last edited by
            #7

            @dmnc This is strange as you said you can build from QtCreator

            https://forum.qt.io/topic/113070/qt-code-of-conduct

            D 1 Reply Last reply
            0
            • jsulmJ jsulm

              @dmnc This is strange as you said you can build from QtCreator

              D Offline
              D Offline
              dmnc
              wrote on last edited by
              #8

              @jsulm I googled a few days,but there seems no one get the same problem0_1534145382777_211.png 0_1534145389182_222.png

              jsulmJ 1 Reply Last reply
              0
              • D dmnc

                @jsulm I googled a few days,but there seems no one get the same problem0_1534145382777_211.png 0_1534145389182_222.png

                jsulmJ Offline
                jsulmJ Offline
                jsulm
                Lifetime Qt Champion
                wrote on last edited by
                #9

                @dmnc Can you show the content of the pro file?
                What happens when you execute qmake (any errors/warnings)?
                Also, Executable at host should contain file name, right?

                https://forum.qt.io/topic/113070/qt-code-of-conduct

                D 1 Reply Last reply
                0
                • jsulmJ jsulm

                  @dmnc Can you show the content of the pro file?
                  What happens when you execute qmake (any errors/warnings)?
                  Also, Executable at host should contain file name, right?

                  D Offline
                  D Offline
                  dmnc
                  wrote on last edited by
                  #10

                  @jsulm
                  pic 1:qamke 0_1534145912884_223.png

                  pic 2:show file system:
                  0_1534145981703_224.png

                  pic 3:build project,I have already build before.
                  0_1534146074081_225.png

                  1 Reply Last reply
                  0
                  • kkoehneK Offline
                    kkoehneK Offline
                    kkoehne
                    Moderators
                    wrote on last edited by
                    #11

                    You said you tried different versions of Qt Creator, but have you also tried with the latest one (Qt Creator 4.7)?

                    take_first() is part of the qmake language since Qt 5.8.0 / Qt Creator 4.1.0. Qt Creator does contain it's own copy of the qmake parser, and therefore you need a recent version of Qt Creator to open .pro files with a recent version of Qt ...

                    Director R&D, The Qt Company

                    D 3 Replies Last reply
                    1
                    • kkoehneK kkoehne

                      You said you tried different versions of Qt Creator, but have you also tried with the latest one (Qt Creator 4.7)?

                      take_first() is part of the qmake language since Qt 5.8.0 / Qt Creator 4.1.0. Qt Creator does contain it's own copy of the qmake parser, and therefore you need a recent version of Qt Creator to open .pro files with a recent version of Qt ...

                      D Offline
                      D Offline
                      dmnc
                      wrote on last edited by dmnc
                      #12

                      @kkoehne the version of mine is 3.3.0(opensource),I will try the latest version now.

                      1 Reply Last reply
                      0
                      • kkoehneK kkoehne

                        You said you tried different versions of Qt Creator, but have you also tried with the latest one (Qt Creator 4.7)?

                        take_first() is part of the qmake language since Qt 5.8.0 / Qt Creator 4.1.0. Qt Creator does contain it's own copy of the qmake parser, and therefore you need a recent version of Qt Creator to open .pro files with a recent version of Qt ...

                        D Offline
                        D Offline
                        dmnc
                        wrote on last edited by
                        #13

                        @kkoehne thankx for your advise ,it woks!!!I installed qtCreator4.6.2,and the error has gone。but remote deploy function still not work ,the “Executable on device” field still shows the error:Executable path not set。

                        1 Reply Last reply
                        0
                        • kkoehneK kkoehne

                          You said you tried different versions of Qt Creator, but have you also tried with the latest one (Qt Creator 4.7)?

                          take_first() is part of the qmake language since Qt 5.8.0 / Qt Creator 4.1.0. Qt Creator does contain it's own copy of the qmake parser, and therefore you need a recent version of Qt Creator to open .pro files with a recent version of Qt ...

                          D Offline
                          D Offline
                          dmnc
                          wrote on last edited by
                          #14

                          @kkoehne I'm sorry, I wrote a wrong line in .pro file.Thank you very much,now ,all problem gone!

                          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