why fabric release 1.1.0 could not make? - hyperledger-fabric

From fabric makefile ,I wanna compile the orderer and peer ,It throws the error
friendsdeMacBook-Pro:fabric friends$ make orderer
make: *** No rule to make target `build/bin/orderer', needed by `orderer'. Stop.
friendsdeMacBook-Pro:fabric friends$
I changed the official makefile a little, my changed Makefile file:
changed Makefile

After taking a git clone of https://github.com/hyperledger/fabric check which branch or tag you are in before invoking make commands.
$ git clone of https://github.com/hyperledger/fabric
$ git checkout v1.1.0
$ make release

Related

How to apply patch file of dtsi(or dts) in yocto

I'm using yocto(ver.rocko) on ubuntu 18.04 and trying to apply patch file but I can't...
My target machine is qemuarm64 and linux kernel is linux-yocto.
Once do $ bitbake core-image-base, kernel source files are unpacked then target dtsi file is located at poky/build/tmp/work/aarch64-poky-linux/linux-libc-headers/4.12-r0/linux-4.12/arch/arm64/boot/dts/arm/juno-base.dtsi
And my custom meta-data files to patch are below:
poky/meta-custom/recipes-kernel/linux/linux-yocto_4.12.bbappend
poky/meta-custom/recipes-kernel/linux/files/juno-base.dtsi.patch
# poky/meta-custom/recipes-kernel/linux/linux-yocto_4.12.bbappend
FILESEXTRAPATHS_prepend := "${THISDIR}/files"
SRC_URI += "file://juno-base.dtsi.patch"
But after bitbake, patch file is created at poky/build/tmp/work/qemuarm64-poky-linux/linux-yocto/4.12.28+gitAUTOINC+2ae65226f6_e562267bae-r0/juno-base.dtsi.patch and patch-application doesn't work
I don't know what's wrong, what to do...
Plz let me know what should I do?
To create a simple patch for Yocto recipe sources, you can use git command in a simple way:
Your Linux work directory is:
poky/build/tmp/work/qemuarm64-poky-linux/linux-yocto/4.12.28+gitAUTOINC+2ae65226f6_e562267bae-r0
as you can see it is already a "git" directory which means that it is intialized with git already.
Here are clear steps for you to understand the method:
After adding your patch(juno-base.dtsi.patch) to SRC_URI I think your linux-yocto work directory is messed up, so follow me:
Clean the build
bitbake linux-yocto -c cleansstate
Remove the patch from SRC_URI
Apply any default patches
bitbake linux-yocto -c patch
Go to
poky/build/tmp/work/qemuarm64-poky-linux/linux-yocto/4.12.28+gitAUTOINC+2ae65226f6_e562267bae-r0
Make your modifications on
poky/build/tmp/work/qemuarm64-poky-linux/linux-yocto/4.12.28+gitAUTOINC+2ae65226f6_e562267bae-r0/arch/arm64/boot/dts/arm/juno-base.dtsi
and not in
poky/build/tmp/work/aarch64-poky-linux/linux-libc-headers/4.12-r0/linux-4.12/arch/arm64/boot/dts/arm/juno-base.dtsi
Now, open a terminal and change directory to
poky/build/tmp/work/qemuarm64-poky-linux/linux-yocto/4.12.28+gitAUTOINC+2ae65226f6_e562267bae-r0
Run: git status (You should see something like: modified arch/arm64/boot/dts/arm/juno-base.dtsi)
Run: git add arch/arm64/boot/dts/arm/juno-base.dtsi
Run: git commit -m "Patch for juni base dtsi"
Run: git format-patch -1
Now a new patch is created with the name "Patch-for-juni-base-dtsi.patch",
Now you can add it to linux-yocto_%.bbappend:
SRC_URI_append = " file://Patch-for-juni-base-dtsi.patch"
If the dtsi is not exist and you want to add it as a patch, do the same thing, when you run "git status" you will see a new added file, add it with "git add" and continue the commands.
After all of this, you can continue the build process with:
bitbake linux-yocto -C patch
Or, if you add the patch to SRC_URI the linux-yocto build will start from do_fetch.

Rust - Failed to create package

I'm following the basic steps here: file:///Users/leongaban/.rustup/toolchains/stable-x86_64-apple-darwin/share/doc/rust/html/book/ch01-03-hello-cargo.html
I checked my cargo version, and cd .. back up to my root project folders and ran the following command to create a new project:
cargo new hello_cargo
And it threw the following error:
error: Failed to create package hello_cargo at /Users/leongaban/projects/rust_projects/hello_cargo
However when I run ls it did create the folder? So I'm curious how do I avoid that error in the future?
rust_projects % cargo new hello_cargo
error: Failed to create package `hello_cargo` at `/Users/leongaban/projects/rust_projects/hello_cargo`
Caused by:
could not find '/Users/leongaban/.git-templates/' to stat: No such file or directory; class=Os (2); code=NotFound (-3)
rust_projects % ls
hello_cargo hello_world
This maybe caused by git init command invoked when you run cargo new, the source code is as below:
if !path.join(".git").exists() {
// Temporary fix to work around bug in libgit2 when creating a
// directory in the root of a posix filesystem.
// See: https://github.com/libgit2/libgit2/issues/5130
paths::create_dir_all(path)?;
GitRepo::init(path, config.cwd())?;
}
And the .git-templates is documented under git init TEMPLATE DIRECTORY section.
The template directory will be one of the following (in order):
the argument given with the --template option;
the contents of the $GIT_TEMPLATE_DIR environment variable;
the init.templateDir configuration variable; or
the default template directory: /usr/share/git-core/templates.
So you should check above 4 possible cause to setup the non-exists folder '/Users/leongaban/.git-templates/' as git tempalte dir when run git init.
I also had this problem. My environment:
System: MacOS Catalina (version: 10.15.7)
Rustc version: rustc 1.51.0
Solution:
rustup self install
curl https://sh.rustup.rs -sSf | sh
I had a template defined in my gitconfig
[init]
templatedir = /Users/johndye/.git-templates
I am not sure when this got added or why but commenting it out got me past this error

How to use an own kernel configuration for a raspberry pi in yocto?

I like to remove some unused drivers for my RPI2 + custom board. For that I am creating an own configuration via:
bitbake linux-raspberrypi -c menuconfig
and save the new kernel preset to the file defconfig.
After this I created an append file for the linux-raspberryp recipe.
So I created the file
linux-raspberrypi%.bbappend
and filled it with:
FILESEXTRAPATHS_prepend := "${THISDIR}/linux-raspberrypi:"
SRC_URI += "file://defconfig"
PACKAGE_ARCH = "raspberrypi2"
I put the defconfig file to:
<meta-mylayer>/recipes-kernel/linux/linux-raspberrypi/raspberrypi2/defconfig
When recompiling the kernel via:
bitbake linux-raspberrypi -c clean
bitbake linux-raspberrypi
The standard RPI2 configuration is taken.
Any idea how to overcome this problem?
I am working on the "actual" pyro branch of meta-raspberrypi and yocto.
Well, unfortunately, the easiest way is probably to patch the kernel source... Or copy your defconfig over the in kernel-tree one.
The meta-raspberrypi layer does some unfortunate things in their kernel recipes, and even though this has become better with time, they're still not really nice...
If you take a look at recipes-kernel/linux/linux-raspberrypi.inc, the following lines explains the issue:
KERNEL_DEFCONFIG_raspberrypi2 ?= "bcm2709_defconfig"
do_kernel_configme_prepend() {
install -m 0644 ${S}/arch/${ARCH}/configs/${KERNEL_DEFCONFIG} ${WORKDIR}/defconfig || die "No default configuration for ${MACHINE} / ${KERNEL_DEFCONFIG} available."
}
Thus,they're copying the in-tree defconfig to ${WORKDIR}/defconfig, thereby overwriting your own defconfig.
You in you .bbappend, you could try to add:
do_kernel_configme_prepend() {
install -m 0644 ${WORKDIR}/defconfig ${S}/arch/${ARCH}/configs/${KERNEL_DEFCONFIG} || die "No default configuration for ${MACHINE} / ${KERNEL_DEFCONFIG} available."
}
Thus, first overwriting the in-kernel-tree one with your own defconfig.
Please take a look at how to use devtool to modify source code for the jethro:
http://www.yoctoproject.org/docs/2.0/dev-manual/dev-manual.html#using-devtool-in-your-workflow
I would start by having a fork at the git repository that it is using;
http://git.yoctoproject.org/cgit/cgit.cgi/meta-raspberrypi/tree/recipes-kernel/linux/linux-raspberrypi_4.9.bb
Using devtool in Yocto;
in your build directory: create a my-linux-raspberry folder;
mkdir linux-raspberry-test
devtool modify -x linux-raspberry ./my-linux-raspberry
This will put unpack the source code into my-linux-raspberry for you to modify; It also create the git repository in there;
Then, modify the code in my-linux-raspberry; To test build, run devtool build linux-raspberry; Once you are satisfied, add this git repository to your fork;
git add .
git commit -m "my-linux-raspberry"
devtool update-recipe linux-raspberry
Optional: run devtool reset linux-raspberry to remove the bbappend file;

Makefile.inc: No such file or directory

I don't have much experience with makefiles, but I am trying to compile and run the program "hdf5ToMds.c" found on this Github repository: https://github.com/MDSplus/mdsplus/tree/alpha/hdf5
My steps towards using the Makefile.in in the folder were as follows:
autoscan
mv configure.scan configure.ac
aclocal
autoheader
autoconf
./configure
make
Now when I run the make I get the error:
Makefile:1: Makefile.inc: No such file or directory
make: *** No rule to make target 'Makefile.inc'. Stop.
Am I missing something obvious? I'm not very familiar with this whole process of getting the code from Github and having to make it. I do have the entire repository cloned, just in case that's relevant.

How to build the C simulator of rocket chip

I get the following error when build the C simulator:
~/rocket-chip/emulator$ make
make: *** No rule to make target /home/rocket-chip/emulator/generated-src/Top.DefaultConfig.prm, needed by /home/rocket-chip/emulator/generated-src/consts.DefaultConfig.h. Stop.
As described in the Rocket Chip README.md, you need to update submodules after cloning the repo:
cd /home/rocket-chip
git submodule update --init --recursive
After this completes, the C emulator should build. Note that you must have the RISC-V tools installed as well; follow the steps in README.md for details.

Resources