Help!

how to add a new file to deb when dpkg-builcpackage

 
  

Post new topic   General Reply to Topic (not reply to a specific post)    Forums Home -> PacKaGe RSS
Next:  Panic with 2 quad opterons (2346)  
Author Message
tangke
External


Since: Aug 04, 2009
Posts: 4



PostPosted: Tue Aug 04, 2009 12:10 am    Post subject: how to add a new file to deb when dpkg-builcpackage
Archived from groups: linux>debian>maint>dpkg (more info?)

hi all,
I download the the src of kpowersave and changed some code,
now i want to add a new file to this deb, and i can automaticly product
the deb that contains it.
how can i do it?

thanks
best regards


--
To UNSUBSCRIBE, email to debian-dpkg-REQUEST.TakeThisOut@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster.TakeThisOut@lists.debian.org
Back to top
Jonathan Yu
External


Since: Apr 03, 2009
Posts: 20



PostPosted: Tue Aug 04, 2009 12:10 am    Post subject: Re: how to add a new file to deb when dpkg-builcpackage [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Hi:

On Mon, Aug 3, 2009 at 10:27 PM, tangke<tangk.TakeThisOut@lemote.com> wrote:
> hi all,
> I download the the src of kpowersave and changed some code,
> now i want to add a new file to this deb, and i can automaticly product the
> deb that contains it.
> how can i do it?
I would suggest overrides (debhelper 7.0.50 and later supports this),
though if you changed the source code then I would suggest using quilt
to do it.

I'm not entirely sure what you're trying to accomplish, so perhaps
explaining that is a better place to start.

If you are patching upstream code for redistribution, leave the source
intact and edit it through quilt. Then use the "--with quilt" target
(available in debhelper 7.0.8 and later) like so:

%:
<TAB>dh --with quilt $@

For a tutorial on how to use quilt, you can see what the pkg-perl
group uses as a reference:

http://pkg-perl.alioth.debian.org/howto/quilt.html

Once you do this, you will be able to build the package as per normal
(via dpkg-buildpackage) and quilt will be run as appropriate.

Come to think about it, my initial response about using overrides is
probably a red herring. You probably want to just use quilt, which
does not require overrides at all.

Here is a reference I wrote on using debhelper in some common
(Perl-package-specific mostly) scenarios, for example if you need to
remove a file from installation.
http://pkg-perl.alioth.debian.org/debhelper.html

Hope this helps.

Cheers,

Jonathan


--
To UNSUBSCRIBE, email to debian-dpkg-REQUEST.TakeThisOut@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster.TakeThisOut@lists.debian.org
Back to top
tangke
External


Since: Aug 04, 2009
Posts: 2



PostPosted: Tue Aug 04, 2009 12:10 am    Post subject: Re: how to add a new file to deb when dpkg-builcpackage [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

sorry, this is a example:
dpkg -c XXXX.deb
/usr/bin/a

now , I want to add /usr/bin/b to this deb package
dpkg -c XXXX.deb

we know, that an
when use commands "dpkg-buildpackage" ,then will compile and in the
debian directory
will have a directory named XXXX, and i can add a new file in this
directory.

but i want to do it automaticlly.
some deb source i download from "apt-get source", after i
dpkg-buildpackage ,the deb package producted already
have some doc,locale file, how can i add a new directory or file?

thanks in advance
best regards

On 08/04/2009 10:57 AM, Jonathan Yu wrote:
> Hi:
>
> On Mon, Aug 3, 2009 at 10:27 PM, tangke<tangk RemoveThis @lemote.com> wrote:
>
>> hi all,
>> I download the the src of kpowersave and changed some code,
>> now i want to add a new file to this deb, and i can automaticly product the
>> deb that contains it.
>> how can i do it?
>>
> I would suggest overrides (debhelper 7.0.50 and later supports this),
> though if you changed the source code then I would suggest using quilt
> to do it.
>
> I'm not entirely sure what you're trying to accomplish, so perhaps
> explaining that is a better place to start.
>
> If you are patching upstream code for redistribution, leave the source
> intact and edit it through quilt. Then use the "--with quilt" target
> (available in debhelper 7.0.8 and later) like so:
>
> %:
> <TAB>dh --with quilt $@
>
> For a tutorial on how to use quilt, you can see what the pkg-perl
> group uses as a reference:
>
> http://pkg-perl.alioth.debian.org/howto/quilt.html
>
> Once you do this, you will be able to build the package as per normal
> (via dpkg-buildpackage) and quilt will be run as appropriate.
>
> Come to think about it, my initial response about using overrides is
> probably a red herring. You probably want to just use quilt, which
> does not require overrides at all.
>
> Here is a reference I wrote on using debhelper in some common
> (Perl-package-specific mostly) scenarios, for example if you need to
> remove a file from installation.
> http://pkg-perl.alioth.debian.org/debhelper.html
>
> Hope this helps.
>
> Cheers,
>
> Jonathan
>
>
>


--
To UNSUBSCRIBE, email to debian-dpkg-REQUEST RemoveThis @lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster RemoveThis @lists.debian.org
Back to top
Steve Langasek
External


Since: Dec 13, 2004
Posts: 2140



PostPosted: Tue Aug 04, 2009 4:10 am    Post subject: Re: how to add a new file to deb when dpkg-builcpackage [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On Tue, Aug 04, 2009 at 11:12:07AM +0800, tangke wrote:
> sorry, this is a example:
> dpkg -c XXXX.deb
> /usr/bin/a

> now , I want to add /usr/bin/b to this deb package
> dpkg -c XXXX.deb

> we know, that an
> when use commands "dpkg-buildpackage" ,then will compile and in the
> debian directory
> will have a directory named XXXX, and i can add a new file in this
> directory.

This mailing list is for the development of the dpkg package manager. I
suggest you direct your questions to the debian-mentors mailing list.

--
Steve Langasek Give me a lever long enough and a Free OS
Debian Developer to set it on, and I can move the world.
Ubuntu Developer http://www.debian.org/
slangasek.DeleteThis@ubuntu.com vorlon.DeleteThis@debian.org


--
To UNSUBSCRIBE, email to debian-dpkg-REQUEST.DeleteThis@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster.DeleteThis@lists.debian.org
Back to top
tangke
External


Since: Aug 04, 2009
Posts: 4



PostPosted: Tue Aug 04, 2009 4:10 am    Post subject: Re: how to add a new file to deb when dpkg-builcpackage [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

On 08/04/2009 03:14 PM, Steve Langasek wrote:
> debian-mentors mailing list
thanks, i will be gone


--
To UNSUBSCRIBE, email to debian-dpkg-REQUEST.RemoveThis@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster.RemoveThis@lists.debian.org
Back to top
Display posts from previous:   
Post new topic   General Reply to Topic (not reply to a specific post)    Forums Home -> PacKaGe All times are: Eastern Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum