You are not logged in.

#1 2009-03-22 04:19:27

useche
Member
From: Miami
Registered: 2006-10-09
Posts: 10
Website

Arch Linux package format

Hi Guys,

I have been playing around with pacman in the freebsd operating system. My goal is just to install a package into the freebsd system with pacman (no dependencies for now). The idea is to compile the software with the freebsd ports system, make a freebsd package and convert that to a pacman package to install it. I could not find information of the package format of pacman. However, both packages format look very similar, so I think the conversion should be straight forward.

Do you know of any documentation of the pacman package format? Are there any tools that can help me with this?

Thanks in advance,

Luis.


Luis Useche

Offline

#2 2009-03-22 05:16:08

FrozenFox
Member
From: College Station, TX
Registered: 2008-03-23
Posts: 422
Website

Offline

#3 2009-03-22 05:54:48

Xilon
Member
Registered: 2007-01-01
Posts: 243

Re: Arch Linux package format

PKGBUILDs and the format in which pacman stores metadata are different. PKGBUILDs are for makepkg consumption. When creating the package, makepkg creates a sort of ini file - .PKGINFO. This file has all the metadata about the package. This file, along with all the package files, and an .INSTALL file, if an install scriptlet is used, are compressed into a pacman package. I'd suggest you simply download an archlinux package, extract it somewhere, and have a look at .PKGINFO. It's a very simple format to parse,

I'm not sure how easy it would be to actually track the files from the ports install. I assume ports has a way of listing all files of a package.

Offline

#4 2009-03-22 09:37:56

fukawi2
Ex-Administratorino
From: .vic.au
Registered: 2007-09-28
Posts: 6,224
Website

Re: Arch Linux package format

AFAIK, they are normal tarballs, with all the appropriate files ready to be extracted to / (ie, /usr/bin/rsync)

tar xvzf packagename.pkg.tar.gz

There is also the .PKGINFO file with specific info for pacman. Extracting a package, and examining the PKGINFO file should give you some good stuff.

Offline

#5 2009-03-23 03:00:20

useche
Member
From: Miami
Registered: 2006-10-09
Posts: 10
Website

Re: Arch Linux package format

Thank you guys. After some thinking, I was just wondering if it is probably easier to convert freebsd ports to PKGBUILD and use the makepkg tool to compile the applications. But this probably deserves another post.

Thanks again.


Luis Useche

Offline

#6 2009-03-24 00:46:37

Ranguvar
Member
Registered: 2008-08-12
Posts: 2,549

Re: Arch Linux package format

I think it'd be more work to write an auto-converter (and deal with bad PKGBUILDs it makes) than to just manually write PKGBUILDs -- they're beyond simple smile

Offline

#7 2009-03-24 01:13:22

Allan
Pacman
From: Brisbane, AU
Registered: 2007-06-09
Posts: 11,400
Website

Re: Arch Linux package format

makepkg should work fine on BSD although you might need to get the git version.  There have been several patches to improve compatibility with BSD and Mac OSX,

Offline

#8 2009-03-24 05:21:28

Xilon
Member
Registered: 2007-01-01
Posts: 243

Re: Arch Linux package format

Allan wrote:

makepkg should work fine on BSD although you might need to get the git version.  There have been several patches to improve compatibility with BSD and Mac OSX,

I can't really speak for BSD compatibility, but makepkg (stable) works fine on Mac OS X, beyond the lack of fakeroot support (on the OS). I believe repo-add has only recently been patched up to work, so you'd need the git version for that (and possibly other complementary tools).

Either way it would be good to try it and report any incompatibilities on the mailing list/bug tracker smile.

Last edited by Xilon (2009-03-24 05:21:39)

Offline

#9 2009-04-03 18:11:18

dschauer
Member
Registered: 2008-02-28
Posts: 95

Re: Arch Linux package format

Ranguvar wrote:

I think it'd be more work to write an auto-converter (and deal with bad PKGBUILDs it makes) than to just manually write PKGBUILDs -- they're beyond simple smile

I agree. Additionally many ports stop and want you fill out options which would further complicate.

I'm intrigued by the idea of having a pacman based BSD system, though in the long run it would warrant it's own BSD distro (ArchBSD if you will), and would not be that useful on top of Free/Net/Open BSD.

I would envision ArchBSD based on an ArchBSD ABS tree, and not on ports. (Although ports would be a primary reference for how to build packages).

The options for ports brings the same problems that Gentoo useflags have into the mix. How does one deal will variations of a package, and are those variations part of the dependency information? Just food for thought...

Offline

#10 2009-04-04 19:49:45

devyn
Member
Registered: 2009-01-01
Posts: 20

Re: Arch Linux package format

Is the "size" field in PKGINFO necessary? I know how to make it... but I'd rather not.

Offline

Board footer

Powered by FluxBB