zoukankan      html  css  js  c++  java
  • builtroot 添加git 下载方式

    1、buildroot/Config.in 配置default git server

    eg:config xxxx_GIT_SITE

        string "git site"
        default "git@gitlab.xxxxxxx.com"

    2、buildroot/package/pkg-download.mk 设置下载命令

    --------------------------------------------------------------------------------------------------------------------

    define DOWNLOAD_GIT_SRC
        rm -rf $($(PKG)_SRCDIR) && \
        git clone $($(PKG)_SITE) $($(PKG)_SRCDIR)
    endef

    --------------------------------------------------------------------------------------------------------------------

    define DOWNLOAD_INNER
      $(Q)$(if $(filter bzr cvs git hg svn svn_src git_src,$($(PKG)_SITE_METHOD)),export BR_NO_CHECK_HASH_FOR=$(2);) \
      if test -n "$(call qstrip,$(BR2_PRIMARY_SITE))" ; then \
        case "$(call geturischeme,$(BR2_PRIMARY_SITE))" in \
          file) $(call $(3)_LOCALFILES,$(BR2_PRIMARY_SITE)/$(2),$(2)) && exit ;; \
          scp) $(call $(3)_SCP,$(BR2_PRIMARY_SITE)/$(2),$(2)) && exit ;; \
          *) $(call $(3)_WGET,$(BR2_PRIMARY_SITE)/$(2),$(2)) && exit ;; \
        esac ; \
      fi ; \
      if test "$(BR2_PRIMARY_SITE_ONLY)" = "y" ; then \
        exit 1 ; \
      fi ; \
      if test -n "$(1)" ; then \
        case "$($(PKG)_SITE_METHOD)" in \
          git) $($(3)_GIT) && exit ;; \
          svn) $($(3)_SVN) && exit ;; \
          svn_src) $($(3)_SVN_SRC) && exit ;; \
          git_src) $($(3)_GIT_SRC) && exit ;; \
          cvs) $($(3)_CVS) && exit ;; \
          bzr) $($(3)_BZR) && exit ;; \
          file) $($(3)_LOCALFILES) && exit ;; \
          scp) $($(3)_SCP) && exit ;; \
          hg) $($(3)_HG) && exit ;; \
          *) $(call $(3)_WGET,$(1),$(2)) && exit ;; \
        esac ; \
      fi ; \
      if test -n "$(call qstrip,$(BR2_BACKUP_SITE))" ; then \
        $(call $(3)_WGET,$(BR2_BACKUP_SITE)/$(2),$(2)) && exit ; \
      fi ; \
      exit 1
    endef

  • 相关阅读:
    linux下shell显示-bash-4.1#不显示路径解决方法
    update chnroute
    An error "Host key verification failed" when you connect to other computer by OSX SSH
    使用dig查询dns解析
    DNS被污染后
    TunnelBroker for EdgeRouter 后记
    mdadm详细使用手册
    关于尼康黄的原因
    Panda3d code in github
    Python实例浅谈之三Python与C/C++相互调用
  • 原文地址:https://www.cnblogs.com/Malphite/p/7268951.html
Copyright © 2011-2022 走看看