I am trying to compile my favorite nano command-line text editor with some of the options.Actually, most of the options in order to enable all features.First, I go to Downloads directory and download the tarball:cd Downloadswget --continue https://www.nano-editor.org/dist/v2.8/nano-2.8.0.tar.xzThen, I verify its integrity:wget --continue https://www.nano-editor.org/dist/v2.8/nano-2.8.0.tar.xz.ascgpg --verify nano-2.8.0.tar.xz.ascIt should say:gpg: Good signature from Benno Schulenberg <bensberg@justemail.net>I have tried to run the configuration script as follows:./configure --enable-nanorc --enable-color --enable-extra --enable-multibuffer --enable-utf8 --enable-libmagic --enable-speller --disable-wrapping-as-rootAfter compilation, I end up with this; directly executed in the compiled directory:Compiled options: --disable-libmagic ...I stress the:--disable-libmagicAs I specifically configured it with:--enable-libmagic    After no success:I delete the folder to start the process over:rm -rf nano-2.8.0/I extract again the archive:tar -xJf nano-2.8.0.tar.xzI have tried different combinations of options, but no luck.Is there anything missing in the system or am I just doing something wrong?Direct execution after the compilation:user@computer ~/Downloads/nano-2.8.0/src $ ./nano --versionGNU nano, version 2.8.0(C) 1999..2016 Free Software Foundation, Inc.(C) 2014..2017 the contributors to nanoEmail: nano@nano-editor.org Web: https://nano-editor.org/Compiled options: --disable-libmagic --disable-wrapping-as-root --enable-utf8
Compiling Nano editor with options
compiling;nano
Nano doesn't store the compiled options as provided on the ./configure command-line, it reconstructs them based on detected features and the requested target (tiny Nano or normal Nano). For tiny Nano, it reports enabled options, since they add to the default; for normal Nano, it reports disabled options, since they remove from the default (in most cases).In your case, you're building normal Nano, so for most options it only reports if they're disabled; the exceptions are debug, utf8 and slang. All your --enable options are defaults for normal Nano, so it doesn't report them in the compiled options; you'd get the same result with ./configure and no options. You end up with --disable-magic because you don't have the development files for libmagic (see Thomas Dickey's answer), and with --enable-utf8 because you do have the necessary features for UTF-8 support (and it's enabled by default).