• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Can'tlocatefind.plin@INC(@INCcontains:/etc/perlxxxx)atperlpath.plline7.

原作者: [db:作者] 来自: [db:来源] 收藏 邀请
/**********************************************************************
 *   Can't locate find.pl in @INC (@INC contains: /etc/perl xxxx) at perlpath.pl line 7.
 * 说明:
 *     在Ubuntu 18.04上编译Yocto,出现的find.pl找不到的问题,只需要将find.pl放在
 * /etc/perl目录就行了。
 *
 *                                2018-6-14 深圳 宝安西乡 曾剑锋
 *********************************************************************/

一、参考文档:
    1. Can't locate find.pl in @INC issue when bitbake meta-toolchain On Yocto Project
        https://community.nxp.com/thread/451990
    2. Yocto : find.pl not found
        https://community.nxp.com/docs/DOC-333675
    3. Missing find.pl compiling OE
        http://blog.kempj.co.uk/2015/09/missing-find-pl-compiling-oe/

二、解决方法:
    1. simply placed the file in /etc/perl. The contents of the file, which should be called find.pl:
        warn "Legacy library @{[(caller(0))[6]]} will be removed from the Perl core distribution in the next major release. Please install it from the CPAN distribution Perl4::CoreLibs. It is being used at @{[(caller)[1]]}, line @{[(caller)[2]]}.\n";
        
        # This library is deprecated and unmaintained. It is included for
        # compatibility with Perl 4 scripts which may use it, but it will be
        # removed in a future version of Perl. Please use the File::Find module
        # instead.
        
        # Usage:
        #    require "find.pl";
        #
        #    &find('/foo','/bar');
        #
        #    sub wanted { ... }
        #        where wanted does whatever you want.  $dir contains the
        #        current directory name, and $_ the current filename within
        #        that directory.  $name contains "$dir/$_".  You are cd'ed
        #        to $dir when the function is called.  The function may
        #        set $prune to prune the tree.
        #
        # For example,
        #
        #   find / -name .nfs\* -mtime +7 -exec rm -f {} \; -o -fstype nfs -prune
        #
        # corresponds to this
        #
        #    sub wanted {
        #        /^\.nfs.*$/ &&
        #        (($dev,$ino,$mode,$nlink,$uid,$gid) = lstat($_)) &&
        #        int(-M _) > 7 &&
        #        unlink($_)
        #        ||
        #        ($nlink || (($dev,$ino,$mode,$nlink,$uid,$gid) = lstat($_))) &&
        #        $dev < 0 &&
        #        ($prune = 1);
        #    }
        #
        # Set the variable $dont_use_nlink if you're using AFS, since AFS cheats.
        
        use File::Find ();
        
        *name        = *File::Find::name;
        *prune        = *File::Find::prune;
        *dir        = *File::Find::dir;
        *topdir        = *File::Find::topdir;
        *topdev        = *File::Find::topdev;
        *topino        = *File::Find::topino;
        *topmode    = *File::Find::topmode;
        *topnlink    = *File::Find::topnlink;
        
        sub find {
            &File::Find::find(\&wanted, @_);
        }
        
        1;

 


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PerlFASTA文件拆分合并发布时间:2022-07-22
下一篇:
一些常用的正则表达式:(PERL兼容)发布时间:2022-07-22
热门推荐
热门话题
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap