All of lore.kernel.org
 help / color / mirror / Atom feed
* install: cannot create regular file Permission denied #dunfell
@ 2022-09-14 18:16 Mahendra Sondagar
  2022-09-14 21:57 ` [yocto] " Steve Sakoman
  2022-09-15  8:01 ` Quentin Schulz
  0 siblings, 2 replies; 4+ messages in thread
From: Mahendra Sondagar @ 2022-09-14 18:16 UTC (permalink / raw)
  To: yocto


[-- Attachment #1.1: Type: text/plain, Size: 1298 bytes --]

Hi.. there

Hope all are doing well

I'm working with the Yocto dunfell branch with the STM32MP1
My goal is to add the test.sh script in to the rootfs of the Yocto custom image (in to the bindir)

That's how, i have created the recipes file called "recipes-support"
Inside that, i have created "net-cfg" file
the files under net-cfg file at where, i have kept test.sh file
here is the tree structure

.
└── net-cfg
├── files
│   └── test.sh
└── net-cfg_1.0.bb

I have installed the image with the custom-image.bb file as a
IMAGE_INSTALL += "net-cfg"

The content of the net-cfg_1.0.bb are as follows
--------------------------------------------------------------------------------------
SUMMARY= "Script files for the testing"
SRC_URI = " file://test.sh"

LICENSE = "CLOSED"

do_install() {
install -d ${D}${bindir}
install -m 0755 ${WORKDIR}/test.sh ${D}${bindir} /
}

FILES_${PN} += "${bindir}/test.sh"

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

During the baking the image, i got the error like *| install: cannot create regular file '/test.sh': Permission denied*

I have attached the full error logs here

Can any one help me here to figure out the issue ?

Thanks
Mahendra

[-- Attachment #1.2: Type: text/html, Size: 1648 bytes --]

[-- Attachment #2: error.txt --]
[-- Type: text/plain, Size: 3281 bytes --]

Log data follows:
| DEBUG: Executing python function extend_recipe_sysroot
| NOTE: Direct dependencies are ['/home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/poky/meta/recipes-devtools/quilt/quilt-native_0.66.bb:do_populate_sysroot', '/home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/poky/meta/recipes-core/glibc/glibc_2.31.bb:do_populate_sysroot', 'virtual:native:/home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/poky/meta/recipes-devtools/patch/patch_2.7.6.bb:do_populate_sysroot', '/home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/poky/meta/recipes-devtools/gcc/gcc-runtime_9.3.bb:do_populate_sysroot', 'virtual:native:/home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/poky/meta/recipes-devtools/pseudo/pseudo_git.bb:do_populate_sysroot', '/home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/poky/meta/recipes-devtools/gcc/gcc-cross_9.3.bb:do_populate_sysroot']
| NOTE: Installed into sysroot: []
| NOTE: Skipping as already exists in sysroot: ['quilt-native', 'glibc', 'patch-native', 'gcc-runtime', 'pseudo-native', 'gcc-cross-arm', 'automake-native', 'libtool-native', 'attr-native', 'autoconf-native', 'gnu-config-native', 'libgcc', 'linux-libc-headers', 'libmpc-native', 'mpfr-native', 'binutils-cross-arm', 'xz-native', 'texinfo-dummy-native', 'zlib-native', 'gmp-native', 'flex-native', 'gettext-minimal-native', 'm4-native']
| DEBUG: Python function extend_recipe_sysroot finished
| DEBUG: Executing shell function do_install
| install: cannot create regular file '/test.sh': Permission denied
| install: omitting directory '/home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/poky/build-mp1/tmp/work/cortexa7t2hf-neon-vfpv4-poky-linux-gnueabi/net-cfg/1.0-r0/image/usr/bin'
| WARNING: exit code 1 from a shell command.
| ERROR: Execution of '/home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/poky/build-mp1/tmp/work/cortexa7t2hf-neon-vfpv4-poky-linux-gnueabi/net-cfg/1.0-r0/temp/run.do_install.18252' failed with exit code 1
ERROR: Task (/home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/meta-custom/recipes-support/net-cfg/net-cfg_1.0.bb:do_install) failed with exit code '1'
NOTE: Tasks Summary: Attempted 3711 tasks of which 3710 didn't need to be rerun and 1 failed.
NOTE: The errors for this build are stored in /home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/poky/build-mp1/tmp/log/error-report/error_report_20220914181359.txt
You can send the errors to a reports server by running:
  send-error-report /home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/poky/build-mp1/tmp/log/error-report/error_report_20220914181359.txt [-s server]
NOTE: The contents of these logs will be posted in public if you use the above command with the default server. Please ensure you remove any identifying or proprietary information when prompted before sending.

Summary: 1 task failed:
  /home/mahendra/STM32MPU_workspace/Digikey_YoctoSeries/Digikey_Yocto/meta-custom/recipes-support/net-cfg/net-cfg_1.0.bb:do_install
Summary: There were 2 WARNING messages shown.
Summary: There was 1 ERROR message shown, returning a non-zero exit code.

real	0m19.681s
user	0m1.373s
sys	0m0.199s


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [yocto] install: cannot create regular file Permission denied #dunfell
  2022-09-14 18:16 install: cannot create regular file Permission denied #dunfell Mahendra Sondagar
@ 2022-09-14 21:57 ` Steve Sakoman
  2022-09-15  8:01 ` Quentin Schulz
  1 sibling, 0 replies; 4+ messages in thread
From: Steve Sakoman @ 2022-09-14 21:57 UTC (permalink / raw)
  To: Mahendra Sondagar; +Cc: yocto

On Wed, Sep 14, 2022 at 8:16 AM Mahendra Sondagar
<mahendrasondagar08@gmail.com> wrote:
>
> Hi.. there
>
> Hope all are doing well
>
> I'm working with the Yocto dunfell branch with the STM32MP1
> My goal is to add the test.sh script in to the rootfs of the Yocto custom image (in to the bindir)
>
> That's how, i have created the recipes file called "recipes-support"
> Inside that, i have created "net-cfg" file
> the files under net-cfg file at where, i have kept test.sh file
> here is the tree structure
>
> .
> └── net-cfg
>     ├── files
>     │   └── test.sh
>     └── net-cfg_1.0.bb
>
> I have installed the image with the custom-image.bb file as a
> IMAGE_INSTALL += "net-cfg"
>
> The content of the net-cfg_1.0.bb are as follows
> --------------------------------------------------------------------------------------
> SUMMARY= "Script files for the testing"
> SRC_URI = " file://test.sh"
>
> LICENSE = "CLOSED"
>
> do_install() {
>         install -d ${D}${bindir}
>         install -m 0755 ${WORKDIR}/test.sh ${D}${bindir} /
I don't think you intended to have this space here            ^

That's why it is attempting to install test.sh to /

Steve

> }
>
> FILES_${PN} += "${bindir}/test.sh"
>
> --------------------------------------------------------------------------------------
>
> During the baking the image, i got the error like | install: cannot create regular file '/test.sh': Permission denied
>
> I have attached the full error logs here
>
> Can any one help me here to figure out the issue ?
>
> Thanks
> Mahendra
>
>
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#58042): https://lists.yoctoproject.org/g/yocto/message/58042
> Mute This Topic: https://lists.yoctoproject.org/mt/93683834/3620601
> Mute #dunfell:https://lists.yoctoproject.org/g/yocto/mutehashtag/dunfell
> Group Owner: yocto+owner@lists.yoctoproject.org
> Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [steve@sakoman.com]
> -=-=-=-=-=-=-=-=-=-=-=-
>


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [yocto] install: cannot create regular file Permission denied #dunfell
  2022-09-14 18:16 install: cannot create regular file Permission denied #dunfell Mahendra Sondagar
  2022-09-14 21:57 ` [yocto] " Steve Sakoman
@ 2022-09-15  8:01 ` Quentin Schulz
  2022-09-18 16:39   ` Mahendra Sondagar
  1 sibling, 1 reply; 4+ messages in thread
From: Quentin Schulz @ 2022-09-15  8:01 UTC (permalink / raw)
  To: Mahendra Sondagar, yocto

Hi Mahendra,

On 9/14/22 20:16, Mahendra Sondagar wrote:
> Hi.. there
> 
> Hope all are doing well
> 
> I'm working with the Yocto dunfell branch with the STM32MP1
> My goal is to add the test.sh script in to the rootfs of the Yocto custom image (in to the bindir)
> 
> That's how, i have created the recipes file called "recipes-support"
> Inside that, i have created "net-cfg" file
> the files under net-cfg file at where, i have kept test.sh file
> here is the tree structure
> 
> .
> └── net-cfg
> ├── files
> │   └── test.sh
> └── net-cfg_1.0.bb
> 
> I have installed the image with the custom-image.bb file as a
> IMAGE_INSTALL += "net-cfg"
> 
> The content of the net-cfg_1.0.bb are as follows
> --------------------------------------------------------------------------------------
> SUMMARY= "Script files for the testing"
> SRC_URI = " file://test.sh"
> 
> LICENSE = "CLOSED"
> 
> do_install() {
> install -d ${D}${bindir}
> install -m 0755 ${WORKDIR}/test.sh ${D}${bindir} /

Spurious slash at the end of the line, it tries to install 
${WORKDIR}/test.sh and ${D}${bindir} to / (root directory of your build 
machine).

Just remove it.

Cheers,
Quentin


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [yocto] install: cannot create regular file Permission denied #dunfell
  2022-09-15  8:01 ` Quentin Schulz
@ 2022-09-18 16:39   ` Mahendra Sondagar
  0 siblings, 0 replies; 4+ messages in thread
From: Mahendra Sondagar @ 2022-09-18 16:39 UTC (permalink / raw)
  To: Quentin Schulz; +Cc: yocto

[-- Attachment #1: Type: text/plain, Size: 1519 bytes --]

Hi...Quentin Schulz

Thanks a lot!
It's solved my issue

Many thanks again :)

Regards
Mahendra

On Thu, Sep 15, 2022 at 1:31 PM Quentin Schulz <
quentin.schulz@theobroma-systems.com> wrote:

> Hi Mahendra,
>
> On 9/14/22 20:16, Mahendra Sondagar wrote:
> > Hi.. there
> >
> > Hope all are doing well
> >
> > I'm working with the Yocto dunfell branch with the STM32MP1
> > My goal is to add the test.sh script in to the rootfs of the Yocto
> custom image (in to the bindir)
> >
> > That's how, i have created the recipes file called "recipes-support"
> > Inside that, i have created "net-cfg" file
> > the files under net-cfg file at where, i have kept test.sh file
> > here is the tree structure
> >
> > .
> > └── net-cfg
> > ├── files
> > │   └── test.sh
> > └── net-cfg_1.0.bb
> >
> > I have installed the image with the custom-image.bb file as a
> > IMAGE_INSTALL += "net-cfg"
> >
> > The content of the net-cfg_1.0.bb are as follows
> >
> --------------------------------------------------------------------------------------
> > SUMMARY= "Script files for the testing"
> > SRC_URI = " file://test.sh"
> >
> > LICENSE = "CLOSED"
> >
> > do_install() {
> > install -d ${D}${bindir}
> > install -m 0755 ${WORKDIR}/test.sh ${D}${bindir} /
>
> Spurious slash at the end of the line, it tries to install
> ${WORKDIR}/test.sh and ${D}${bindir} to / (root directory of your build
> machine).
>
> Just remove it.
>
> Cheers,
> Quentin
>

[-- Attachment #2: Type: text/html, Size: 3509 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-09-18 16:40 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-14 18:16 install: cannot create regular file Permission denied #dunfell Mahendra Sondagar
2022-09-14 21:57 ` [yocto] " Steve Sakoman
2022-09-15  8:01 ` Quentin Schulz
2022-09-18 16:39   ` Mahendra Sondagar

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.