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

apt-get -o's



I'm trying to get the -o options to work so that I can pass dpkg
options along.  I was told by someone that

apt-get \
 -o Dpkg::Options::=--force-confmiss \
 -o Dpkg::Options::=--force-somethingelse \
 ....

would send options to dpkg from apt.  I'm having a hard time verifying
that this works.  I'm using the form:

  apt-get -o DIR=root -o Dpkg::Options::=--root=root update

in order to compose a local (non-root) cache of packages.  Apt-get
seems happy with it all.  dpkg complains that I cannot write
/var/dpkg/lock which makes me think it doesn't know about the root
option.  Can you shed some light on this?

I figured this might be simple to debug so I fetched the source and
built apt-get.  Trouble is that there are no line numbers for the code
where dpkg is forked.  I'm guessing it is in a library where the
symbols have been stripped.

So, I'm wondering if you can suggest something.  Is the syntax
correct?  I also tried passing obviously illegal switches
"--badoption" and the like.  No reaction from dpkg.

If it helps, here is the script I'm using to setup the root directory
tree.

  #!/bin/sh
  #
  #
  
  [ -d root ] && rm -rf root
  mkdir -p root
  mkdir -p root/etc/apt
  cp sources.list root/etc/apt
  mkdir -p root/var/cache/apt/archives/partial
  mkdir -p root/var/lib/apt/lists/partial
  mkdir -p root/var/lib/dpkg


And here is my sources.list.

  deb http://ftp.us.debian.org/debian unstable main contrib non-free
  deb http://non-us.debian.org/debian-non-US unstable non-US/main non-US/contrib non-US/non-free



Reply to: