{
  "id": "cmake/autogen-uic-not-found",
  "signature": "CMake Error: AUTOGEN: No valid Qt 'uic' executable found for target 'myapp'",
  "signature_zh": "CMake 错误：AUTOGEN：未找到目标 'myapp' 的有效 Qt 'uic' 可执行文件",
  "regex": "AUTOGEN: No valid Qt .uic. executable found for target",
  "domain": "cmake",
  "category": "build_error",
  "subcategory": null,
  "root_cause": "Qt5/Qt6 AUTOMOC/AUTOUIC/AUTORCC requires uic binary in PATH or via Qt5_DIR/Qt6_DIR, but it's missing or version mismatched.",
  "root_cause_type": "generic",
  "root_cause_zh": "Qt5/Qt6 的 AUTOMOC/AUTOUIC/AUTORCC 需要 uic 可执行文件在 PATH 中或通过 Qt5_DIR/Qt6_DIR 指定，但 uic 缺失或版本不匹配。",
  "versions": [
    {
      "version": "Qt5 5.15.2",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "Qt6 6.5.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "CMake 3.28",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "CMake 3.29",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "Reinstall Qt and set CMAKE_PREFIX_PATH to the install root",
      "why_fails": "If only the library is installed without the development tools (uic, moc), find_package(Qt5) might succeed but uic is still missing.",
      "fail_rate": 0.3,
      "condition": "",
      "sources": []
    },
    {
      "action": "Set CMAKE_AUTOUIC OFF and manually run uic",
      "why_fails": "Turning off AUTOUIC bypasses the error but leaves UI compilation unhandled, causing linker errors later.",
      "fail_rate": 0.4,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Install Qt development tools: sudo apt install qtbase5-dev qtbase5-dev-tools (or qttools5-dev for uic). Then reconfigure.",
      "success_rate": 0.85,
      "how": "Install Qt development tools: sudo apt install qtbase5-dev qtbase5-dev-tools (or qttools5-dev for uic). Then reconfigure.",
      "condition": "",
      "sources": []
    },
    {
      "action": "Explicitly set the uic path in CMake: set(QT_UIC_EXECUTABLE /usr/lib/qt5/bin/uic) before find_package(Qt5).",
      "success_rate": 0.75,
      "how": "Explicitly set the uic path in CMake: set(QT_UIC_EXECUTABLE /usr/lib/qt5/bin/uic) before find_package(Qt5).",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "安装 Qt 开发工具：sudo apt install qtbase5-dev qtbase5-dev-tools（或 qttools5-dev 以获取 uic）。然后重新配置。",
    "在 CMake 中显式设置 uic 路径：在 find_package(Qt5) 之前设置 set(QT_UIC_EXECUTABLE /usr/lib/qt5/bin/uic)。"
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": null,
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.85,
  "fix_success_rate": 0.82,
  "resolvable": "true",
  "first_seen": "2024-03-15",
  "last_confirmed": "2024-06-01",
  "last_updated": "2024-06-01",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}