Last active
May 2, 2022 08:50
-
-
Save harukaeru/652f1814c495944537a736e14ed8a8ab to your computer and use it in GitHub Desktop.
The script that makes python installed from Homebrew available in C/C++ on Mac OS X
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ ln -s /usr/local/Cellar/[email protected]/3.10.1/Frameworks/Python.framework/Versions/3.10/include/python3.10/* /usr/local/include | |
$ which gj | |
gj: aliased to /usr/local/Cellar/gcc/11.2.0_3/bin/g++-11 -D GLIBCXX_DEBUG -Wl,-demangle -std=c++17 -Wall -Werror -fsanitize=undefined -O2 -g | |
$ which aa | |
aa () { | |
if [[ -z $1 ]] | |
then | |
./a.out | |
else | |
cat $1 | ./a.out | |
fi | |
} | |
$ gj $(python3-config --cflags --embed) $(python3-config --embed --ldflags) pyt.cpp |
Author
harukaeru
commented
May 2, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment