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

Re: Problem with Synaptic



On Friday 12 November 2021 13:38:48 Greg Wooledge wrote:

> On Fri, Nov 12, 2021 at 08:19:15AM -0500, Gene Heskett wrote:
> > On Friday 12 November 2021 07:36:01 Eduardo M KALINOWSKI wrote:
> > > On 12/11/2021 09:30, Stephen P. Molnar wrote:
> > > > This is the immediate problem that I need to fix:
> > > >
> > > > comp@AbNormal:~$ sudo apt upgrade
> > > > Reading package lists... Done
> > > > Building dependency tree
> > > > Reading state information... Done
> > > > E: The package brscan4 needs to be reinstalled, but I can't find
> > > > an archive for it.
> > > >
> > > > sudo apt update ran without any problems.
> > >
> > > Try downloading it again (since it's not part of the archives, it
> > > must be downloaded manually) and running 'apt install
> > > ./brscan4-......deb' (substituting the actual file name,
> > > naturally). The './' is necessary to tell apt it's a file name.
> >
> > No, to be precise, it tells the file system its a file in the
> > currently cd'd to directory.  Which may not be in the env's $PATH.
>
> It's both, Gene.
>
> To the file system (kernel), ./foo is a relative pathname that's 100%
> equivalent to foo.  There's no difference at all.
>
> However, to apt-get or apt, ./foo and foo are very different
> arguments. The former is a relative path to a file, and the latter is
> a package name.
>
> This has nothing to do with $PATH, because we're not talking about
> running a program from the current directory.  We're talking about
> apt-get and apt specifically.
>
> You're thinking of the conventional use of "./configure" and so on to
> run a program in the current directory.  This is necessary because
> PATH should never contain "." (or the empty string) as one of its
> components.  That would allow the execution of *anything* at all in
> the current directory (the way MS-DOS works).  This is a huge security
> problem on a multi-user system, where someone could leave a script in
> /tmp hoping for you to run it accidentally.
>
> It *works* because the shell bypasses the PATH search if the command
> that you give it contains a slash character.  ./configure means "run
> the program named configure in the current directory, and don't search
> anywhere else".

Thanks Greg, a better view than mine.

Cheers, Gene Heskett.
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author, 1940)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page <http://geneslinuxbox.net:6309/gene>


Reply to: