Discussion:
[Users] [Bug 4061] New: --prefix configure option doesn't work correctly on 'make uninistall'
n***@thewildbeast.co.uk
2018-07-26 12:07:16 UTC
Permalink
https://www.thewildbeast.co.uk/claws-mail/bugzilla/show_bug.cgi?id=4061

Bug ID: 4061
Summary: --prefix configure option doesn't work correctly on
'make uninistall'
Classification: Unclassified
Product: Claws Mail
Version: GIT
Hardware: PC
OS: Linux
Status: NEW
Severity: major
Priority: P3
Component: Other
Assignee: ***@lists.claws-mail.org
Reporter: ***@anchev.net

STR:

cd /tmp
rm -rf claws
git clone git://git.claws-mail.org/claws.git
cd /tmp/claws
./autogen.sh

█ Note the --prefix value:

./configure \
--build=$(uname -m)-suse-linux-gnu \
--prefix=/usr \
--disable-jpilot \
--disable-maintainer-mode \
--disables-manual \
--disable-static \
--enable-bogofilter-plugin \
--enable-crash-dialog \
--enable-enchant \
--enable-gnutls \
--enable-ldap \
--enable-pgpmime-plugin \
--enable-silent-rules \
--enable-spamassassin-plugin \
--disable-dillo-plugin \
--disable-fancy-plugin

make
su -
cd /tmp/claws
make install
make uninistall

█ Note: the output shows many attempts to remove files from '/usr/local'
instead of '/usr' as specified in the --prefix above

which claws-mail


EXPECTED:

which: no claws-mail in
(/sbin:/usr/sbin:/usr/local/sbin:/root/bin:/usr/local/bin:/usr/bin:/bin:/usr/lib/mit/sbin)


ACTUAL:

/usr/bin/claws-mail

Additionally directories like /usr/lib64/claws-mail/plugins/ remain. (I don't
know which others too since I am not familiar with the whole tree structure)
--
You are receiving this mail because:
You are the assignee for the bug.
n***@thewildbeast.co.uk
2018-07-26 12:18:30 UTC
Permalink
https://www.thewildbeast.co.uk/claws-mail/bugzilla/show_bug.cgi?id=4061

--- Comment #1 from George <***@anchev.net> ---
Correction:

I obviously have a typo: --disables-manual should be --disable-manual due to
which the prefix is ignored.

After correcting this changes the ACTUAL to:

Empty (nested) directories remain in /usr/include/claws-mail, in
/usr/lib64/claws mail (and perhaps others). I.e. as far as I understand the
'make uninstall' should remove those directories too but it doesn't.
--
You are receiving this mail because:
You are the assignee for the bug.
n***@thewildbeast.co.uk
2018-07-26 12:20:46 UTC
Permalink
https://www.thewildbeast.co.uk/claws-mail/bugzilla/show_bug.cgi?id=4061

George <***@anchev.net> changed:

What |Removed |Added
----------------------------------------------------------------------------
Summary|--prefix configure option |'make uninistall' leaves
|doesn't work correctly on |empty directories
|'make uninistall' |
--
You are receiving this mail because:
You are the assignee for the bug.
n***@thewildbeast.co.uk
2018-07-26 12:32:34 UTC
Permalink
https://www.thewildbeast.co.uk/claws-mail/bugzilla/show_bug.cgi?id=4061

--- Comment #2 from George <***@anchev.net> ---
Testing the same scenario with --prefix=/opt:

After running 'make uninstall' the following structure remains:

[/opt]: tree
.
├── bin
│   └── sylpheed-claws -> claws-mail
├── include
│   └── claws-mail
│   ├── common
│   ├── etpan
│   ├── gtk
│   └── plugins
│   └── pgpcore
├── lib64
│   ├── claws-mail
│   │   └── plugins
│   └── pkgconfig
└── share
├── applications
├── doc
│   └── claws-mail
├── icons
│   └── hicolor
│   ├── 128x128
│   │   └── apps
│   ├── 48x48
│   │   └── apps
│   └── 64x64
│   └── apps
├── locale
│   ├── ca
│   │   └── LC_MESSAGES
│   ├── cs
│   │   └── LC_MESSAGES
│   ├── da
│   │   └── LC_MESSAGES
│   ├── de
│   │   └── LC_MESSAGES
│   ├── en_GB
│   │   └── LC_MESSAGES
│   ├── es
│   │   └── LC_MESSAGES
│   ├── fi
│   │   └── LC_MESSAGES
│   ├── fr
│   │   └── LC_MESSAGES
│   ├── hu
│   │   └── LC_MESSAGES
│   ├── id_ID
│   │   └── LC_MESSAGES
│   ├── it
│   │   └── LC_MESSAGES
│   ├── ja
│   │   └── LC_MESSAGES
│   ├── nb
│   │   └── LC_MESSAGES
│   ├── nl
│   │   └── LC_MESSAGES
│   ├── pl
│   │   └── LC_MESSAGES
│   ├── pt_BR
│   │   └── LC_MESSAGES
│   ├── ro
│   │   └── LC_MESSAGES
│   ├── ru
│   │   └── LC_MESSAGES
│   ├── sk
│   │   └── LC_MESSAGES
│   ├── sv
│   │   └── LC_MESSAGES
│   ├── tr
│   │   └── LC_MESSAGES
│   └── zh_TW
│   └── LC_MESSAGES
└── man
└── man1

71 directories, 1 file
--
You are receiving this mail because:
You are the assignee for the bug.
Paul
2018-07-26 12:47:29 UTC
Permalink
On Thu, 26 Jul 2018 12:32:34 +0000
George, instead of jumping up and down, waving your arms, at the
periphery (i.e. itemising every last thing you can think of), why not
just walk inside and try to fix things? You would surely save energy
that way.
George Anchev
2018-07-26 13:00:28 UTC
Permalink
Post by Paul
George, instead of jumping up and down, waving your
arms, at the periphery (i.e. itemising every last
thing you can think of), why not just walk inside
and try to fix things? You would surely save energy
that way.
Sorry, Paul. I didn't mean to sound like "waving my
arms" or waste anyone's energy. I just tried to
provide necessary details about what I found.

By 'fix things' - what do you mean? I would be glad to
help but I have never worked with makefiles. I don't
know which particular script takes care of cleaning up
after uninstall and what is really supposed to remain
as a final structure.

--
George
n***@thewildbeast.co.uk
2018-07-26 12:57:37 UTC
Permalink
https://www.thewildbeast.co.uk/claws-mail/bugzilla/show_bug.cgi?id=4061

Ricardo Mones <***@users.sourceforge.net> changed:

What |Removed |Added
----------------------------------------------------------------------------
Severity|major |minor

--- Comment #3 from Ricardo Mones <***@users.sourceforge.net> ---
https://stackoverflow.com/questions/19521335

Research is done, waiting for your patch ;-)
--
You are receiving this mail because:
You are the assignee for the bug.
n***@thewildbeast.co.uk
2018-07-26 18:56:46 UTC
Permalink
https://www.thewildbeast.co.uk/claws-mail/bugzilla/show_bug.cgi?id=4061

--- Comment #4 from George <***@anchev.net> ---
I suppose the relevant thing would be to add lines to the existing
uninstall-hook target based on the the mkdir lines from /po/Makefile.in.in,
perhaps using:

find <dir> -type d -empty -delete && rmdir <dir>

However I can't provide a patch as I am not familiar with the intricacies of
the variable names used. I tried to figure those out by looking at the code of
the various files but still - it looks all interrelated and complex.
--
You are receiving this mail because:
You are the assignee for the bug.
n***@thewildbeast.co.uk
2018-12-06 19:45:46 UTC
Permalink
https://www.thewildbeast.co.uk/claws-mail/bugzilla/show_bug.cgi?id=4061

Andrej Kacian <***@kacian.sk> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |WONTFIX

--- Comment #5 from Andrej Kacian <***@kacian.sk> ---
"make uninstall" is not supposed to remove empty directories, just files. As
its own documentation states, the "uninstall" target is not meant to be a
replacement for package management, see
https://www.gnu.org/software/automake/manual/automake.html#index-installdirs

The only bug here is that the "sylpheed-claws" symlink is not removed, we will
be fixing that soon.
--
You are receiving this mail because:
You are the assignee for the bug.
Loading...