You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I thought I'd try my hand at creating a Gentoo package for Yuescript, but I'm running into a few issues. If you want, you can read the forum post I made, but I'll try to outline the relevant issues here.
Building against different Lua implementations.
In Gentoo, you can add the ability to build certain packages against certain language versions, either multiple or single. In the case of fennel, you can build it against Lua 5.3, 5.4 or LuaJIT, not all 3. See the ebuild (it's somewhat like PKGBUILD) for fennel here.
To do this for Yuescript, I'm unsure. Using Gentoo's functionality to build Yuescript against LuaJIT, I notice that it will build with -DLUA_COMPAT_5_3. Obviously one probably doesn't want this if they want to build against Lua 5.4 or LuaJIT. How to change this specifically I imagine involves patching something in a (c)makefile.
User CFLAGS are ignored
Another Gentoo thing is that you can set your CFLAGS universally for all packages, as well as LDFLAGS and so on. See the wiki page for /etc/portage/make.conf if you want to look at it in more detail.
It seems the makefiles for Yuescript will ignore these entirely, as it will build with
This excludes a lot of flags that I've set, and I suspect the build is also ignoring that I've set the default linker to be mold. Again, maybe this involves patching something in a (c)makefile.
Resulting yue executable should go in /usr/bin
This is likely the simplest thing, but in Gentoo package's executables should go in /usr/bin not /usr/local/bin. Again, probably another patch situation or just overriding some envvar Yuescript's (c)makefiles will read.
To clarify, when I say "patch" I don't mean anyone here needs to change something in the project. In Gentoo, one can have package specific patches that can be applied before building said package. These could be for project build files (makefiles) or files in the source code itself.
I can make the patches, I just need to know what needs to be patched.
The text was updated successfully, but these errors were encountered:
Hello!
I thought I'd try my hand at creating a Gentoo package for Yuescript, but I'm running into a few issues. If you want, you can read the forum post I made, but I'll try to outline the relevant issues here.
Building against different Lua implementations.
In Gentoo, you can add the ability to build certain packages against certain language versions, either multiple or single. In the case of fennel, you can build it against Lua 5.3, 5.4 or LuaJIT, not all 3. See the ebuild (it's somewhat like PKGBUILD) for fennel here.
To do this for Yuescript, I'm unsure. Using Gentoo's functionality to build Yuescript against LuaJIT, I notice that it will build with
-DLUA_COMPAT_5_3
. Obviously one probably doesn't want this if they want to build against Lua 5.4 or LuaJIT. How to change this specifically I imagine involves patching something in a (c)makefile.User CFLAGS are ignored
Another Gentoo thing is that you can set your
CFLAGS
universally for all packages, as well asLDFLAGS
and so on. See the wiki page for /etc/portage/make.conf if you want to look at it in more detail.It seems the makefiles for Yuescript will ignore these entirely, as it will build with
This excludes a lot of flags that I've set, and I suspect the build is also ignoring that I've set the default linker to be mold. Again, maybe this involves patching something in a (c)makefile.
Resulting
yue
executable should go in/usr/bin
This is likely the simplest thing, but in Gentoo package's executables should go in
/usr/bin
not/usr/local/bin
. Again, probably another patch situation or just overriding some envvar Yuescript's (c)makefiles will read.To clarify, when I say "patch" I don't mean anyone here needs to change something in the project. In Gentoo, one can have package specific patches that can be applied before building said package. These could be for project build files (makefiles) or files in the source code itself.
I can make the patches, I just need to know what needs to be patched.
The text was updated successfully, but these errors were encountered: