首页 文章

YOCTO上的CUPS Web界面

提问于
浏览
0

我有一个yocto图像,我已经包含了CUPS包(使用 IMAGE_INSTALL_append ) .

运行操作系统时,我找不到 /etc/init.d 中的cups文件 .

我用 cupsd 开始了杯子 . 当我尝试使用 localhost:631 访问Web界面时,我得到了 not found error . 控制台显示它无法在任何这些URL上加载资源:

http://localhost:631/cups.css

http://localhost:631/

http://localhost:631/favicon.ico

html和相关文件似乎列在 cups.inc file中 . 在进行YOCTO构建或CUPS设置之前是否需要进行其他配置更改?

由于我是一个非常新的yocto和在linux环境中开发,我不确定我是否遗漏了一些明显的东西 .

2 回答

  • 1

    你做了很好的研究,指出了食谱,实际上已经接近找到了解决方案 .

    In the recipe,您可以阅读:

    # Remove sysinit script and symlinks if sysvinit is not in DISTRO_FEATURES
    if ${@bb.utils.contains('DISTRO_FEATURES','sysvinit','false','true',d)}; then
        rm -rf ${D}${sysconfdir}/init.d/
        rm -rf ${D}${sysconfdir}/rc*
    fi
    

    你的 DISTRO_FEATURES 中有 sysvinit 吗?

    如果你不知道你能做到

    bitbake cups -e | grep "^DISTRO_FEATURES="
    
  • 2

    这个问题很老了,已经有了一个公认的答案 . 然而,它可能适用于面临同样问题的其他人缺少CUPS Web界面的静态html内容 .

    CUPS配方将静态Web内容打包到cups-doc中 . 因此,而不是

    IMAGE_INSTALL_append = " cups"
    

    它应该是

    IMAGE_INSTALL_append = " cups cups-doc"
    

    在你的conf / local.conf中 . 然后,/ usr / share / doc / cups下的文件也被添加到rootfs中 .

    校验

    # Replace <target>, <image> and <version> to match your configuration
    # e.g.: raspberrypi3-poky-linux-gnueabi/core-image-full-cmdline/1.0-r0
    
    $YOUR_POKY_DIRECTORY/build/tmp/work/<target>/<image>/<version>/rootfs/usr/share/doc/cups
    

    在添加cups-doc包之前完全没有 .

相关问题