[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Simple Debian Package Creation?



On Wed, 2004-11-03 at 21:26 +0100, Bartosz Fenski aka fEnIo wrote:
> On Wed, Nov 03, 2004 at 10:47:45AM -0600, Zach Garner wrote:

> I'd agree it's pretty confusing, but only first time.
> It's quite easy to understand it. 
I'm hoping so, that's why I'm trying not to give up too easily.


> Most of the apps are using `./configure && make && make install` so dh_make
> tries to use that way.
> In fact the only file you need is debian/rules.
> It should be Makefile which create your package.

What bugs me is that as far as I can tell from the documentation,
dh_make is the recommended proper way of doing things. Also, as far as I
can tell I need the following:
README.Debian compat copyright rules control dirs

I understand your point though, the 'rules' file is the only one that
really matters.


> If you really don'y like debhelper's scripts you can always write this
> Makefile yourself or use cdbs (`apt-get install cdbs`).

I'll look into cdbs.

I have some makefiles that work ok, by modifying what I got from dh_make
(this is probably a bad idea, but I don't have documentation on how to
hand write one without using debhelper scripts...). It generally works,
but there is a lot of magic that happens in the dh_ scripts. For
instance, I don't know how it knows that debian/<packagename> is where
my application data is supposed to be. Is this hardcoded in dpkg-deb? Is
somehow expressed in one of the dh_ scripts that is listed in my
"binary:" target. All I really know is that if I put my files there, it
puts them in the package. I probably need to read the man pages more
than I have...

>  
> > Why can't debian package building be as simple as 'dpkg-create
> > foo.spec'?
> > 
> > Second, why can't I create packages with standard unix commands? Why
> > can't I say something like:
> >   $ tar cvzf data.tgz myapplication/*
> >   $ tar czvf control.tgz control
> >   $ tar czvf mypackage-0.1.deb data.tgz control.tgz
> 
> Debian uses standard unix commands. 

What I meant by standard roughly translates into available on most/all
unix or linux systems. The format of a .deb file is special as far as I
can tell. I can't create or manipulate them without using dpkg-deb or
one of the other scripts. 

In fact, I would be happy enough if I could (a) run dpkg-deb on our
other systems, this may be possible, though I don't expect it would too
easy and (b) use dpkg-deb to create a package by giving it the
control.tgz and data.tgz. Ideally, dpkg-deb wouldn't be required to
create the specially formatted deb file, and I could just create a tar.


> > My main complaint here, is that we really want to be able to build the
> > debian packages from any developer workstation. Since we don't impose
> > operating system requirements on developers, we can't expect debian to
> > be on all workstations. 
> 
> Sorry. How do you suppose to build rpm without rpm?
Oh, I didn't mean to imply RPM was better here. My other biases show
here.. I started out with Slackware, and later spent quite a while in
the OpenBSD then FreeBSD world. For all of those .tgz was the standard
format. 

I'm trying my best to put aside my previous habits, and get into the
debian package building way of thought.

>  
> > Right now, using Debian to deploy our software seems more and more
> > difficult for us. I'd greatly appreciate any advice or comments. All I
> > want to be able to do is create a package on any unix system that can be
> > installed via apt-get, that simply installs some files, and can use the
> > pre/post install/remove scripts. This seems like a simple thing to do,
> > but the process seems very difficult.
> 
> Is your software free? Can you share it with us?
> I'm sure that someone create proper packaging scripts for you.
> I'm first to help you if you want.

Unfortunately, it's not. I greatly appreciate the help you've given so
far, and the offer for more help. I can only promise that, if I start to
like the debian package build process, that I will contribute back in my
free time. I was once a FreeBSD package maintainer... 

I can get over part of my complaints. I can deal with the multiple files
in the debian directory, and may come to love it. The layers of scripts,
and the resulting confusing, conflicting documentation is still a
problem. But I expect I can eventually come to an understanding of it
all.

What's still the big problem for us is the need to be on a debian system
to create the packages. From what I can tell, we would likely need a few
packages from debian-unstable on that system as well. 

This isn't a technically insurmountable problem, but it is a snag when
it comes to convincing my supervisors that choosing debian and apt-get
for our production platform was a great idea. (it's probably still the
best idea, but unfortunately, maybe not a great one for our needs)


Thanks

-- 
Zach Garner <zach@awarix.com>



Reply to: