public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
From: Claudius Heine <claudius.heine.ext@siemens.com>
To: Francesco <fdprnd@dave.eu>, isar-users@googlegroups.com
Subject: Re: Install debian packages from other sources
Date: Thu, 19 Apr 2018 15:03:21 +0200	[thread overview]
Message-ID: <0dc39e6b-7769-1ffb-9f5a-1b2f15bab84e@siemens.com> (raw)
In-Reply-To: <6bbe9d5c-73e8-019e-d79c-de2263879795@dave.eu>

Hi,

On 2018-04-19 11:07, Francesco wrote:
> Thanks for the example provided.
> 
> I have now created a custom image file on another layer. Inside this 
> image I set the IMAGE_PREINSTALL variable with other packages I want to 
> install on my final target image.
> 
> At the end of the building process I noticed that the version of the 
> packages does not correspond to the version of the packages of my added 
> repo, but it is instead that from the original repo.

Honestly I haven't tested overwriting upstream packages with ones of the 
same name and older version created by isar very thoroughly yet. It 
should work, because isar-bootstrap adds a pin preference to packages 
from the internal isar repo with a priority of 1000.

But as Henning said, you should make sure that your package is build and 
deployed in the internal isar repo first by adding it to "IMAGE_INSTALL" 
instead of "IMAGE_PREINSTALL". Then the pin priority should take over 
and install yours instead of upstreams.

> I also would like to ask another thing. I tried to write a recipe to 
> install a custom application in .deb format. The deb file is this time 
> fetched from the host fs.
> 
> My custom image inherits from the isar-base-image, and I would like to 
> simply execute dpkg -i mypackage from the target rootfs. How am I 
> supposed to write a recipe for this?

I did something similar before multi-repo support was implemented:

     inherit dpkg-base
     DESCRIPTION = "My Package"
     LICENSE = "gpl-2.0"
     LIC_FILES_CHKSUM = 
"file://${LAYERDIR_isar}/licenses/COPYING.GPLv2;md5=751419260aa954499f7abaabaa882bbe"
     PN = "my-package"
     PV = "1.0.0"
     SRC_URI = 
"https://path/to/server/${PN}_${PV}_${DISTRO_ARCH}.deb;unpack=0"
     SRC_URI[sha256sum] = "xxxx"

     dpkg_runbuild() {
     	echo "Task intentionally left empty"
     }

Cheers,
Claudius

> 
> Thanks
> 
> Frank
> 
> 
> On 19/04/2018 09:10, Claudius Heine wrote:
>> Hi,
>>
>> On 2018-04-18 20:26, Henning Schild wrote:
>>> Hi,
>>>
>>> you can do two things. You can actually go ahead and just fetch .deb
>>> files from somewhere in a package-recipe. Or you could derive and
>>> image-recipe from isar-image-base where you add another sources.list
>>> file to DISTRO_APT_SOURCES.
>>
>> Yes 'DISTRO_APT_SOURCES' is the right variable, but setting it in an 
>> image recipe doesn't do anything. You have to expand it in a *.conf 
>> file or in a isar-bootstrap.bbappend file.
>>
>> Personally I would create a new configs like this:
>>
>>   conf/distro/custom.conf:
>>     require conf/distro/debian-stretch.conf
>>     DISTRO_APT_SOURCES += "conf/distro/custom.list"
>>
>>   conf/distro/custom.list:
>>     deb http://url/to/repo suite component
>>
>>   conf/multiconfig/custom-config.conf:
>>     require conf/multiconfig/qemuamd64-stretch.conf
>>     DISTRO = "custom"
>>
>> For just testing you could also put
>> 'DISTRO_APT_SOURCES_append = " conf/distro/custom.list"'
>> in the local.conf, you will also need the custom.list at the right place.
>>
>> Cheers,
>> Claudius
>>
>>> We still lack an example for that, but Claudius might have one. >
>>> If we are talking about a proper repo and not some random drop-location
>>> for .debs the latter would be the way to go.
>>>
>>> Henning
>>>
>>> Am Wed, 18 Apr 2018 18:12:31 +0200
>>> schrieb Francesco <fdprnd@dave.eu>:
>>>
>>>> Hello again,
>>>>
>>>> I would like to fetch debian packages from other repositories and
>>>> then install them into the rootfs.
>>>>
>>>> Which is the right way to achieve this?
>>>>
>>>> Thanks
>>>>
>>>> Frank
>>>>
>>>>
>>>
>>
> 

-- 
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-54 Fax: (+49)-8142-66989-80 Email: ch@denx.de

  parent reply	other threads:[~2018-04-19 13:03 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-18 16:12 Francesco
2018-04-18 18:26 ` Henning Schild
2018-04-19  7:10   ` Claudius Heine
2018-04-19  9:07     ` Francesco
2018-04-19 12:02       ` Henning Schild
2018-04-19 13:03       ` Claudius Heine [this message]
2018-04-19 14:19         ` Francesco
2018-04-26  9:28           ` Henning Schild

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0dc39e6b-7769-1ffb-9f5a-1b2f15bab84e@siemens.com \
    --to=claudius.heine.ext@siemens.com \
    --cc=fdprnd@dave.eu \
    --cc=isar-users@googlegroups.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox