Bill-Haku/kawaii-gcc
소개
GCC 컴파일러를 귀엽게 만들어 보세요!
프로그래밍 언어 및 런타임측정된 스타 증가
- in 24h
- 0
- in 7 days
- +1
- in 15 days
- +3
- in 1 month
- +1
서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.
README.md
OriginalKawaii-gcc かわいいGCC
Make your GCC compiler kawaii~!
This project makes the output messages from GCC compiler looks kawaii by editing the localization file of GCC.
Everyone is welcomed to contribute and add more kawaii messages!
中文版(更改为中文时请优先阅读)
How to use it?
Linux (in an Ubuntu example)
Install Japanese for your terminal (if not installed)
sudo apt-get install language-pack-ja language-pack-gnome-ja language-pack-ja-base language-pack-gnome-ja-baseInstall
gcc,gettextandg++.sudo apt-get install gcc gettext g++Install
gcc localesCheck your gcc main version number by:
gcc -vIt is 12.3.0 on my end. So the main version number is 12.
sudo apt-get install gcc-12-localesFind your gcc language file. Defaultly, it should be found in
/usr/share/locale/ja/LC_MESSAGES/gcc.mo. However, it is also possible that you cannot find the file or the file is named asgcc-12.mo. If there's a related file, back up it. (eg.sudo mv gcc-12.mo gcc-12.mo.bak) Don't worry if there's no such file, you need to do nothing.Use the following command to download the
mofile in the project and copy it to the path.sudo wget https://github.com/Bill-Haku/kawaii-gcc/raw/main/prebuilt/gcc.mo -O /usr/share/locale/ja/LC_MESSAGES/gcc-12.moThe
gcc.pois the localization file for ja_JP, and thegcc-zh.pois the localization file for zh_CN. See the Chinese version README document for more details.You can also rebuild the binary file by yourself:
msgfmt gcc.po -o gcc.mo sudo cp gcc.mo /usr/share/locale/ja/LC_MESSAGES/gcc-12.moRegarding to the file name:
- If you found an existed file in the last step, use the existed file name.
- if not, try
gcc-<MAIN VERSION NUMBER>.mofirst, and if it doesn't work, rename it togcc.mo.
Change terminal environmental variables into Japanese:
vim ~/.bashrc # Add the following lines export LANG="ja_JP.UTF-8" export LANGUAGE="ja_JP.UTF-8" # Save it in Vim source ~/.bashrcNow your GCC has become kawaii~!
You can have a try with the
test.ccprovided in the project.gcc test.cc -Wall # -Wall makes GCC output all the warning messages.
Windows
Install Cygwin
Download and run setup-x86_64.exe
Choose
Install from Internetat the step ofSelect Packages.At the step of
Select Packages, SetViewasCategoryand search and select the versions ofgcc-core,gcc-g++andgettextunder the ALL/Devel panel.
Suppose your
Cygwininstall directory is<DIR>(Defaultly it should beC:\cygwin), add the directory<DIR>\binto the Environment VariablePath. If there'smingwin thePath, delete it or move it under the<DIR>\bin. Add another Environment VariableLANG, and set the value of it intoja_JP.UTF-8.Move the
gcc.mofile in the./prebuiltdirectory of this repository to<DIR>\usr\share\locale\ja\LC_MESSAGES, keep naming it asgcc.mo. Backuping the existedgcc.mofile is suggested.
macOS
OrbStack:
- Install OrbStack by following OrbStack Quick Start
- Download any Linux distribution image and configure according to the Linux version
- Note 1: Enable desired locales using
locale-gen** Uncomment your preferred language in/etc/locale.gen, e.g.
** Runzh_CN.UTF-8 UTF-8sudo locale-gen - Note 2: Arch Linux users using the AUR
kawaii-gccpackage can copy-paste configurations into zh_CN directory and follow repository instructions - Note 3: Set
LANGandLANGUAGEvariables in shell configurations,for example:
# ~/.bashrc
export LANG="zh_CN.UTF-8"
export LANGUAGE="zh_CN.UTF-8"
# ~/.config/fish/config.fish
set LANG "zh_CN.UTF-8"
set LANGUAGE "zh_CN.UTF-8"
- Add aliases in macOS host's
.zshrc:
# Set your preferred GCC tools
alias gcc='orb gcc'
alias g++='orb g++'
- Environment setup completed
- Note: The compiled output from GCC targets Linux, so you should use
orb ./to run the generated binaries.
Star History
Special Thanks
This project is inspired by gcc-hentai. It was a Chinese project, and I created this repo to make a Japanese version and share it to Japanese users. I added the new text, edited and completed some details in the use instructions, and made a video in Japanese to share it. The video got unexpected attention in Chinese users on Bilibili, so I added contents of Chinese in it. Thanks for the sharing and the open-source spirit of the original authors.
관련 프로젝트 살펴보기
불러오는 중…