m1芯片brew安装openoffice

1、brew安装

brew install openoffice
# 卸载:brew uninstall openoffice

vim ~/.zshrc
#追加以下内容
export PATH=$PATH:/Applications/OpenOffice.app/Contents/MacOS

source ~/.zshrc

# 启动openoffice
soffice -headless -accept="socket,host=localhost,port=8002;urp;" -nofirststartwizard &
目录:/opt/homebrew/Caskroom/openoffice
java代码中使用:officehome配置为/Applications/OpenOffice.app/Contents

2、dmg安装

注意:如果brew无法安装,可以下载指定版本的dmg直接安装

Download Apache_OpenOffice_4.1.3_MacOS_x86-64_install_en-GB.dmg (Apache OpenOffice)

猜你喜欢

转载自blog.csdn.net/kanhcj86/article/details/130735904