homebrew-emacs-plus icon indicating copy to clipboard operation
homebrew-emacs-plus copied to clipboard

`dir` file missing from the Info directory

Open ksqsf opened this issue 3 years ago • 10 comments

The following command

brew install emacs-plus@29 --with-native-comp

installs all info files into /usr/local/Cellar/emacs-plus@29/29.0.50/share/info/emacs. However, this directory does not include a dir file, and the info reader will hence be not able to find these files.

A workaround is to manually install these files by

cd /usr/local/Cellar/emacs-plus@29/29.0.50/share/info/emacs
for f in *.info.gz; do install-info $f dir; done

I hope the emacs-plus formula could do that automatically.

ksqsf avatar Feb 22 '22 15:02 ksqsf

I checked Emacs's build scripts, and it seems that it should have taken care of this by using install-info. I'm not sure what went wrong.

ksqsf avatar Feb 22 '22 15:02 ksqsf

Just chiming in.

Similar experience too, with brew install emacs-plus@28 --with-native-comp on M1 though:

  cd /opt/homebrew/Cellar/emacs-plus@28/28.0.50/share/info/emacs/
  for f in *.info.gz
         do install-info $f dir
  done

augustfengd avatar Mar 04 '22 17:03 augustfengd

Hey folks,

I can't address this issue right now cause I got left without my personal laptop. Have not ETA when I can go back home. So I would gladly accept contributions on this one.

d12frosted avatar Mar 25 '22 08:03 d12frosted

I did a bit of debugging and found that the dir file is actually being created correctly by make; make install, but then it's being deleted in the Cleaning phase:

brew install emacs-plus@29 --verbose
# ...
# Cleaning
# rm /opt/homebrew/Cellar/emacs-plus@29/29.0.50/share/info/emacs/dir

Seems like this is intentional on brew's part, just don't fully understand why.

augustfengd avatar Apr 01 '22 16:04 augustfengd

I also don't understand why they remove them. But it looks like there is a way to skip their cleaning using skip_clean function.

d12frosted avatar May 09 '22 12:05 d12frosted

@d12frosted did you ever figure out how to make use of that function from the command line?

dabrahams avatar Jun 28 '22 05:06 dabrahams

@dabrahams unfortunately no, and I doubt that it's possible to use it from the command line.

d12frosted avatar Jun 28 '22 06:06 d12frosted

Here's what I had to do to get my info files found:

cd /opt/homebrew/share/info
ln -s emacs/* .
mv dir dir.orig
for file in * ; do install-info "$file" dir; done

dabrahams avatar Jun 28 '22 06:06 dabrahams

I have same problem for both emacs-plus@29 and emacs-plus@30, I recently fond emacs-mac merged a pr about it, don't know if it will help: https://github.com/railwaycat/homebrew-emacsmacport/commit/16b401464946dc8391a35fab912c7571bd4ad1b1 @dabrahams I just notice that you provide this fix, thanks! Could you also fix it for emacs-plus 😆

For both M1 and non M1 users:

cd $(brew --prefix)/share/info/emacs
for file in * ; do install-info "$file" dir; done

chuxubank avatar Feb 08 '23 00:02 chuxubank

Don't think it will help, and I quote:

However, it does not deal with the info files since those would require external program install-info to work properly.

dabrahams avatar Feb 08 '23 01:02 dabrahams