致命错误:ui_about.h:没有这样的文件或目录

致命错误:ui_about.h:没有这样的文件或目录

我正在尝试编译以下 github 包

    https://github.com/openalpr/plate_tagger

它利用qt。cmake的输出如下,

    -- The C compiler identification is GNU 4.8.4
    -- The CXX compiler identification is GNU 4.8.4
    -- Check for working C compiler: /usr/bin/cc
    -- Check for working C compiler: /usr/bin/cc -- works
    -- Detecting C compiler ABI info
    -- Detecting C compiler ABI info - done
    -- Check for working CXX compiler: /usr/bin/c++
    -- Check for working CXX compiler: /usr/bin/c++ -- works
    -- Detecting CXX compiler ABI info
    -- Detecting CXX compiler ABI info - done
    -- Configuring done
    -- Generating done
    -- Build files have been written to: /home/tonystark124/plate_tagger-master/build

当我尝试制作时,遇到以下错误:

  [  1%] Built target openalpr_tagger_automoc
  Scanning dependencies of target openalpr_tagger
  [  3%] Building CXX object CMakeFiles/openalpr_tagger.dir/about.cpp.o
  /home/tonystark124/plate_tagger-master/about.cpp:4:22: fatal error: ui_about.h: No such file or directory
  #include "ui_about.h"

我在 git 中提出了一个问题,因为似乎没有其他人遇到过这个障碍。经过进一步搜索,我倾向于得出结论,我缺少一些安装/部分qt5链接1链接2建议这与qt5构建但无法查明实际问题。

我该如何解决这个问题?

更新

已包含我的 CMakeLists.txt

    cmake_minimum_required(VERSION 2.8.11)

    project(openalpr_tagger)

    SET(VERSION_MAJOR 1)
    SET(VERSION_MINOR 0)
    SET(VERSION_PATCH 0)

    SET (VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}")
    add_definitions(-DVERSION_MAJOR=${VERSION_MAJOR})
    add_definitions(-DVERSION_MINOR=${VERSION_MINOR})
    add_definitions(-DVERSION_PATCH=${VERSION_PATCH})
    add_definitions(-DVERSION_STRING="${VERSION}")


    add_definitions(-DTARGET="openalpr_tagger")
    add_definitions(-DTARGET_STRING="openalpr_tagger")
    add_definitions(-DTARGET_UPPER_STRING="OPENALPR_TAGGER")
    add_definitions(-DTARGET_HUMAN_STRING="openalpr_tagger")

    ADD_DEFINITIONS(
        -std=c++11 
    )


    # Find the QtWidgets library
    find_package(Qt5Widgets)

    set(CMAKE_AUTOMOC ON)
    set(CMAKE_AUTOUIC ON)
    set(CMAKE_INCLUDE_CURRENT_DIR ON)

    # Tell CMake to create the helloworld executable
    add_executable(openalpr_tagger 
    about.cpp
    directoryloader.cpp
    dot.cpp
    imagefile.cpp
    imageview.cpp
    imageviewerbase.cpp
    imageviewerobserver.cpp
    imageviewerplateselector.cpp
    main.cpp
    mainwindow.cpp
    options.cpp
    platefile.cpp
    plateselector.cpp
    polygons.cpp
    selection.cpp
    settings.cpp
    squeezedlabel.cpp
    threadedimageloader.cpp
    utils.cpp
    qprogressindicator/QProgressIndicator.cpp

    extra/yaml-cpp/src/nodeevents.cpp
    extra/yaml-cpp/src/exceptions.cpp
    extra/yaml-cpp/src/nodebuilder.cpp
    extra/yaml-cpp/src/contrib/graphbuilder.cpp
    extra/yaml-cpp/src/contrib/graphbuilderadapter.cpp
    extra/yaml-cpp/src/exp.cpp
    extra/yaml-cpp/src/binary.cpp
    extra/yaml-cpp/src/null.cpp
    extra/yaml-cpp/src/parser.cpp
    extra/yaml-cpp/src/convert.cpp
    extra/yaml-cpp/src/scantag.cpp
    extra/yaml-cpp/src/singledocparser.cpp
    extra/yaml-cpp/src/scanner.cpp
    extra/yaml-cpp/src/directives.cpp
    extra/yaml-cpp/src/emitterstate.cpp
    extra/yaml-cpp/src/node_data.cpp
    extra/yaml-cpp/src/scanscalar.cpp
    extra/yaml-cpp/src/scantoken.cpp
    extra/yaml-cpp/src/node.cpp
    extra/yaml-cpp/src/regex_yaml.cpp
    extra/yaml-cpp/src/emitfromevents.cpp
    extra/yaml-cpp/src/emitterutils.cpp
    extra/yaml-cpp/src/tag.cpp
    extra/yaml-cpp/src/memory.cpp
    extra/yaml-cpp/src/simplekey.cpp
    extra/yaml-cpp/src/ostream_wrapper.cpp
    extra/yaml-cpp/src/emit.cpp
    extra/yaml-cpp/src/emitter.cpp
    extra/yaml-cpp/src/stream.cpp
    extra/yaml-cpp/src/parse.cpp

    )

    include_directories(
      ${CMAKE_SOURCE_DIR}/qprogressindicator
      ${CMAKE_SOURCE_DIR}/extra/yaml-cpp/include/
    )

    # Use the Widgets module from Qt 5.
    target_link_libraries(openalpr_tagger Qt5::Widgets)

答案1

我不知道该怎么做,但是制作成功了,如果构建

按照 git 页面的说明,使用制作..代替制作..

相关内容