-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cosmoc? #1
Comments
Cosmoc is just a wrapper to normal gcc with cosmopolitan options. In my case it looks like:
Are you using nixpgks? If so, I can probably upload a decent |
thx, yes i use nix. that would def help!
…On Thu, Nov 4, 2021, 23:10 jacereda ***@***.***> wrote:
Cosmoc is just a wrapper to normal gcc with cosmopolitan options. In my
case it looks like:
exec
/nix/store/s5hkav7whndbfz0szshpb46h4idqdq9a-gcc-wrapper-10.3.0/bin/gcc -Os
-static -nostdlib -nostdinc -fno-pie -no-pie -mno-red-zone
-fno-omit-frame-pointer -pg -mnop-mcount -fno-stack-protector -include
/nix/store/vd0p0ni2ciisy8136niqpwc4c31m0mrh-cosmopolitan-git/lib/include/cosmopolitan.h
"$@" -Wl,--gc-sections -Wl,-z,max-page-size=0x1000 -fuse-ld=bfd
-Wl,-T,/nix/store/vd0p0ni2ciisy8136niqpwc4c31m0mrh-cosmopolitan-git/lib/ape.lds
/nix/store/vd0p0ni2ciisy8136niqpwc4c31m0mrh-cosmopolitan-git/lib/{crt.o,ape.o,cosmopolitan.a}
Are you using nixpgks? If so, I can probably upload a decent default.nix
that setups everything automatically.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABL6ZBZV55MVQ45PCEHTZDUKMAEPANCNFSM5HMPZWJQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
|
Can you try now? Unless I messed something, this should work:
The executable should now work on Linux, Windows, NetBSD and FreeBSD. |
awesome! I can't test right now, but I'll fire up nix asap.
…On Sat, Nov 6, 2021 at 9:19 PM jacereda ***@***.***> wrote:
Can you try now? Unless I messed something, this should work:
cd cosmogfx
nix-shell
./mk
The executable should now work on Linux, Windows, NetBSD and FreeBSD.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABL6ZBFGZTCV5R5TVVRD4TUKWEV3ANCNFSM5HMPZWJQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
--
L Ξ Ο N V Λ N Κ Λ Μ Μ Ξ N
Senior creative technologist & researcher
https://2wa.isvery.ninja/hello
https://www.linkedin.com/in/leonvankammen
|
Thx, this is my output: $ nix-shell
....
66,636⏰ 66,636⏳ 13,488k 0iop o//third_party/python/pythontester.com -m test.test_dictviews
67,056⏰ 67,069⏳ 13,448k 0iop o//third_party/python/pythontester.com -m test.test_dictcomps
78,812⏰ 78,843⏳ 13,452k 0iop o//third_party/python/pythontester.com -m test.test_subclassinit
770,278⏰ 768,053⏳ 49,268k 0iop o//third_party/python/pythontester.com -m test.test_zlib
2,973,721⏰ 2,968,926⏳ 67,988k 472iop o//third_party/python/pythontester.com -m test.test_bz2
installing
rm: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
/bin/sh: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
dircolors: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
uname: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
stty: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
whoami: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
$ |
I see.. Looks like a mess with runtimes. I'll try to simplify it so it doesn't depend on my nixpkgs fork. |
Meanwhile, does |
Can you please try again with the latest changes? |
interesting, it crashed somewhere during the cosmopolitan tests
which is strange because cosmopolitan builds fine outside of nix (~6G free mem):
Since I already had cosmopolitan on my drive, I symlinked it and adjusted $ git clone https://github.com/jacereda/cosmogfx --recurse-submodules
$ cd cosmogfx
cosmogfx $ ln -s ../cosmopolitan .
cosmogfx $ git diff mk
diff --git a/mk b/mk
index 1c886a0..3cc5bba 100755
--- a/mk
+++ b/mk
@@ -1,4 +1,8 @@
#!/usr/bin/env bash
+cosmoc(){
+ cosmopolitan/o/tool/build/compile.com gcc "$@"
+}
+export PATH=$PATH:cosmopolitan/o/tool/build
set -e
install -d b
gcc -s -ffunction-sections -fdata-sections -Wl,-gc-sections -fomit-frame-pointer -Os -pie -fPIC helper.c -o helper/linux -ldl
@@ -13,8 +17,9 @@ cosmoc -DDLOPEN=z_dlopen \
-DELFCLASS=ELFCLASS64 \
-DCV_NO_MAIN \
-DCV_DYN \
- -include cosmopolitan.h \
+ -include cosmopolitan/o/cosmopolitan.h \
-I. \
+ -Icosmopolitan \
-Imicroui/demo \
-Imicroui/src \
-Ifake \ Which got me this output:
|
The first error seems related to jart/cosmopolitan@7064d73 Using your local copy won't work, Nixpkgs is using a very old version and this project needs some recent changes. I've synced with the latest changes, can you pull again and retry? |
573,952⏰ 569,196⏳ 18,708k 0iop o//third_party/python/pythontester.com -m test.test_codecencodings_iso2022
1,095,311⏰ 1,074,030⏳ 21,192k 0iop o//third_party/python/pythontester.com -m test.test_codecmaps_jp
946,283⏰ 944,000⏳ 18,932k 0iop o//third_party/python/pythontester.com -m test.test_codecencodings_jp
4,477,602⏰ 4,472,040⏳ 67,956k 472iop o//third_party/python/pythontester.com -m test.test_bz2
installing
rm: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
/bin/sh: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
dircolors: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
uname: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
stty: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
whoami: symbol lookup error: /nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib/libc.so.6: undefined symbol: _dl_catch_error_ptr, version GLIBC_PRIVATE
(exit)
$
|
Im trying to get the ./mk script to work..but can't find cosmoc in this / the cosmopolitan repo..where to get it?
The text was updated successfully, but these errors were encountered: