Debian Control File: How to tell amd64 arch systems they depend on libudev1:i386

Hi All,

I'm having trouble wrapping my head around the proper way to agnosticly tell any system that is installing my .deb package that it depends on the 32 bit version of libudev. My control file looks something like this:

1
2
3
4
5
6
7
8
9
10
Package: my-package
Version: 1.3-16
Section: non-free/misc
Priority: optional
Architecture: i386
Installed-Size: 350
Depends: libudev1
Maintainer: me <me@me.com>
Description:
 This is my package


This package is intended to be able to be installed on ubuntu 12.04, 12.10 and 13.04, 32 and 64 bit arch on all 3. What I want to do is change Depends: libudev1 to Depends: libudev1:i386 but that doesn't seem to work the way I think it should.

My program is only built for i386, if it is installed on a amd64 machine it is run in 32 bit compatibility mode and relies on the 32 bit version of certain libraries to be installed on the amd64 machine (in /lib/x86_64-linux-gnu or whatever it is) so the dependencies of my binaries can be resolved.
1. Debian package must install on 32 bit and 64 bit operating systems (same package, not a i386 version and amd64 version)
2. Debian package must install the 32 bit version of libudev0 or libudev1

I had considered adding ia32-libs as a dependency but the problem is I don't want my users to have to install a 500 some odd MB package just for one library. There are other problems with this solution as well. If I were to mark the package as dependent on ia32-libs then my 32 bit users would install that package even though they don't need to since libudev is installed by default on ubuntu 12.04-13.04 (hopefully the user didn't remove it!). I really just need to make sure there is some i386 (not amd64) version of libudev installed on any machine my package is installed on.

I also have tried using Depends: ia32-libs [amd64] which should only install ia32-libs on amd64 arch systems. But when I do I get an error from dpkg-deb:

dpkg-deb: error: parsing file 'build/my-package/DEBIAN/control' near line 7 package 'my-package': `Depends' field, syntax error after reference to package `libudev0'


I tried changing my Architecture field to Architecture: any but that didn't help anything.

Am I missing something obvious here?

I know those operating systems have libudev installed by default, but if it's a 64 bit OS it won't have the 32 bit versions of libudev that I've linked my binaries against. Anyone have any ideas as to how I can solve this without building different binaries and/or having mutliple .deb installers for different architectures?

Please let me know if there's anything important I left out or if you have any questions. Thanks in advance!

Here's some extra info about my environment/machine:

$ uname -a
Linux Latitude-E6400 3.8.0-29-generic #42-Ubuntu SMP Tue Aug 13 23:12:18 UTC 2013 i686 i686 i686 GNU/Linux


$ dpkg-deb --version
Debian `dpkg-deb' package archive backend version 1.16.10 (i386).
This is free software; see the GNU General Public License version 2 or


edit: I removed the output of dpkg-architecture -L because it was so huge and probably unnecessary, let me know if anyone would like to see it and I'll post it in another reply.
Last edited on
Topic archived. No new replies allowed.