Code Monkey home page Code Monkey logo

Comments (5)

ohwgiles avatar ohwgiles commented on July 26, 2024

I cannot reproduce this.

  • Are you absolutely sure it is laminar itself that is serving this?
  • I guess you changed LAMINAR_BIND_HTTP such that it is serving on port 6875?
  • Do you get the same result at other static laminar endpoints, such as /style.css, /js/app.js?
  • Can you post the build output of the AUR package? It would be odd, but maybe could be caused by a failure in the embedding of static assets at configure time.
  • Is the gzip binary present where you built the AUR package?

from laminar.

Justasic avatar Justasic commented on July 26, 2024

Are you absolutely sure it is laminar itself that is serving this?

Yes, I changed LAMINAR_BIND_HTTP and verified the laminard process bound to that port with netstat -tupln.

I guess you changed LAMINAR_BIND_HTTP such that it is serving on port 6875?

Correct, though I did rebind the port to other port numbers to verify that was not the issue. (trying both 8080 and 8000)

Do you get the same result at other static laminar endpoints, such as /style.css, /js/app.js?

After testing, yes. It gives the exact same error

Can you post the build output of the AUR package? It would be odd, but maybe could be caused by a failure in the embedding of static assets at configure time.

Sure.

Is the gzip binary present where you built the AUR package?

Yes, It's a standard arch user environment, I did verify the gzip executable exists and functions properly.

Additionally, Since I know the pain of "works for me", I used a tool called libtree to resolve all dynamic libraries used and place them in the executables directory in the attached zip, hopefully this can help replicate the issue.
The zip also includes the build products of makepkg. I have tried to rebuild laminar with both clang and gcc but got the same result. I will see if I can find another arch linux system to attempt this build on, hopefully find what is wrong here.
I did test external browsers with this version of laminar (thinking maybe the browser was messed up) but those browsers returned the same error.

build_output.txt
laminar.zip

from laminar.

ohwgiles avatar ohwgiles commented on July 26, 2024

Thanks for the detail.

Can you please try rebuilding your AUR package without stripping debug symbols? Adding OPTIONS=(!strip) to the PKGBUILD should do this, and you can check whether the binary is stripped using nm.

Does the unstripped version also exhibit this behaviour? If so, please send it to me too.

from laminar.

Justasic avatar Justasic commented on July 26, 2024

Apologies for the delay, life's been hectic.

Your mention of the debug symbols reminded me that I have some pretty aggressive optimizations I did to my makepkg.conf, one of which was using the mold linker instead of regular GNU ld. It seems that attempting to link laminar with mold causes this behavior. I tested with all the flags below but removed mold and laminar rendered the page as expected.

Since mold is still relatively new and this feels out of scope of the project overall, I'll go ahead and close the issue. The flags I was using if you would like to replicate it were the following:

CFLAGS="-march=native -mtune=native -O3 -pipe -fno-plt -ftree-vectorize -D_FORTIFY_SOURCE=2"
CXXFLAGS="-march=native -mtune=native -O3 -pipe -fno-plt -ftree-vectorize -D_FORTIFY_SOURCE=2"
LDFLAGS="-Wl,-O3,--sort-common,--as-needed,-z,relro,-z,now,--strip-debug,-flto -fuse-ld=mold"
OPTIONS=(strip [...])
STRIP_BINARIES="--strip-all"
STRIP_SHARED="--strip-unneeded"
STRIP_STATIC="--strip-debug"

Thanks for your time and helping me debug the issue!

from laminar.

ohwgiles avatar ohwgiles commented on July 26, 2024

Thanks, this is interesting. I'd like to take a closer look at what mold does when I find some time for it.

from laminar.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.