dslm4515 / CMLFS

Clang-Built Musl Linux From Scratch
MIT License
105 stars 18 forks source link

cgnutools: Remove curses dependencies from cgnutools and optimize LLVM builds #46

Closed owl4ce closed 2 years ago

owl4ce commented 3 years ago
Changes:
1. Force turn off linking to curses libraries `LLVM_ENABLE_TERMINFO:BOOL`;
2. Force turn off linking to host's libz `LLVM_ENABLE_ZLIB:BOOL`;
3. etc.

I confirm this works like a charm on my builds, people might need to confirm this first if it's valid. Thanks.

owl4ce commented 3 years ago

Cc: @dslm4515 @takusuman

dslm4515 commented 3 years ago

NO WAY! SO! Maybe this is how i got to build cgnutools w/o linking to ncurses!

I'll check it out!!

owl4ce commented 3 years ago

Why not going back to MinSizeRel for CMAKE_BUILD_TYPE to reduce build time and size?

dslm4515 commented 3 years ago

Why not going back to MinSizeRel for CMAKE_BUILD_TYPE to reduce build time and size?

I initially did, but some headers and binaries were not installed... i might be confusing it with llvmtools, though. Perhaps, MinSizeRel should be used for LLVM in cgnutools and Release for llvmtools and definately Release for the final system

dslm4515 commented 3 years ago

I tried searching for a stripped down LLVM source or a method to strip it down like in cross-tools in MLFS. I even tried to see if i can build clang with out the main LLVM source... that failed as clang expects to build in-tree in LLVM main source. Its crazy how many options have to be turned off. I had to change the format because when the I enter all the flags on one line, it doesn't transfer well from text-file to commanad line

owl4ce commented 3 years ago

Wait, looks like zlib needed by lld.

dslm4515 commented 3 years ago

Wait, looks like zlib needed by lld.

Good catch!

Currently upgrading software on newer laptop as the current one I'm using as a terminal is quite old with small screen (its 1024 x768!) ... newer laptop has a larger screen (1366 x 768)

takusuman commented 3 years ago

Cc: @dslm4515 @takusuman

😳

owl4ce commented 3 years ago

Wait, looks like zlib needed by lld.

Nevermind, mine has worked without any problems at all after rebuilding for 3 days. Previously I had serious problem, somehow ld.lld really needs zlib compression to read musl runtime objects (crt). Now, works like charm! I stick to Release for better performance.

People might need to confirm this first if it's valid. Thanks.

dslm4515 commented 3 years ago

I'm almost ready for another CMLFS build.

Sorry for the delay.