Git Product home page Git Product logo

ops-p4dp's Introduction

How to recreate this repository

The original repository contains "submodules", which Yocto / bitbake support. The original repository also uses autotools, which Yocto / bitbake also support. The problem appears when trying to use both things at the same time: the existing Yocto / bitbake support does not have the concept of configure scripts in multiple subdirectories. The way autotools supports this is by having a statement like this:

AC_CONFIG_SUBDIRS([submodules/bm])

in the toplevel configure.ac. This is the reason why this repository added that file, to be able to drive the configure process of the submodules.

Since trying to manage the submodules proved to be a pain in the context of Yocto, the git submodules were replaced with git subtrees, which creates a single repository with the contents of the submodules added to it. In order to recreate the repository, do this:

$ git remote add -f behavioral-model https://github.com/p4lang/behavioral-model.git
$ git subtree add --prefix submodules/bm behavioral-model master --squash

$ git remote add -f submodules/p4c-bm https://github.com/p4lang/p4c-bm.git
$ git subtree add --prefix submodules/p4c-bm p4c-bm master --squash

If you need to update a subtree, do this:

$ git subtree pull --prefix submodules/bm behavioral-model master --squash

Instead of master, you can use any valid reference (commit, branch, tag). Just keep in mind that it refers to the remote you are specifying and not to local references.

Strictly speaking it's not necessary to add the remotes and you can use the URL in place of the remote name in the corresponding 'git subtree add' line.

git subtree is mostly syntax sugar for adding git trees at specific graft points. This blog post from Atlassian contains a nice summary.

ops-p4dp's People

Contributors

notmem avatar

Watchers

 avatar

Forkers

evelinad

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.