Merge pull request #140612 from sternenseemann/cbqn-no-patch
cbqn: remove vendoring using builtin capabilities
This commit is contained in:
commit
2de004090b
2 changed files with 8 additions and 28 deletions
|
@ -1,15 +0,0 @@
|
|||
diff --git a/makefile b/makefile
|
||||
index a5f3d75..f617e25 100644
|
||||
--- a/makefile
|
||||
+++ b/makefile
|
||||
@@ -109,9 +109,7 @@ ${bd}/%.o: src/builtins/%.c
|
||||
|
||||
|
||||
src/gen/customRuntime:
|
||||
- @echo "Copying precompiled bytecode from the bytecode branch"
|
||||
- git checkout remotes/origin/bytecode src/gen/{compiler,formatter,runtime0,runtime1,src}
|
||||
- git reset src/gen/{compiler,formatter,runtime0,runtime1,src}
|
||||
+ @echo "src/gen/ files retrieved externally"
|
||||
${bd}/load.o: src/gen/customRuntime
|
||||
|
||||
-include $(bd)/*.d
|
|
@ -29,23 +29,18 @@ stdenv.mkDerivation rec {
|
|||
|
||||
dontConfigure = true;
|
||||
|
||||
patches = [
|
||||
# self-explaining
|
||||
./001-remove-vendoring.diff
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
sed -i '/SHELL =.*/ d' makefile
|
||||
'';
|
||||
|
||||
preBuild =
|
||||
if genBytecode
|
||||
then ''
|
||||
${bqn-path} genRuntime ${mbqn-source}
|
||||
''
|
||||
else ''
|
||||
cp ${cbqn-bytecode-files}/src/gen/{compiler,formatter,runtime0,runtime1,src} src/gen/
|
||||
'';
|
||||
preBuild = ''
|
||||
# inform make we are providing the runtime ourselves
|
||||
touch src/gen/customRuntime
|
||||
'' + (if genBytecode then ''
|
||||
${bqn-path} genRuntime ${mbqn-source}
|
||||
'' else ''
|
||||
cp ${cbqn-bytecode-files}/src/gen/{compiler,formatter,runtime0,runtime1,src} src/gen/
|
||||
'');
|
||||
|
||||
makeFlags = [
|
||||
"CC=${stdenv.cc.targetPrefix}cc"
|
||||
|
|
Loading…
Reference in a new issue