Coder Social home page Coder Social logo

crystal_library's People

Contributors

ysbaddaden avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

b-rich

crystal_library's Issues

Update the POC

Hi :)
Now that crystal has support for not generating main , would it be easier to do this with less steps ?

PoC with crystal 0.24.2

Tried your PoC with crystal 0.24.2 on linux 64 bits. Alas did not work, there is no compile option, only a build option. With the build option it does not work

user1 ~/download/try/crystal_library (master) $ make CRYSTAL_ROOT=/opt/crystal
CRYSTAL_PATH="src:/opt/crystal/share/crystal/src" /opt/crystal/bin/crystal build \
	--release --cross-compile -o libcounter src/libcounter.cr
cc 'libcounter.o' -o 'libcounter'  -rdynamic  -lpcre -lgc -lpthread /opt/crystal/share/crystal/src/ext/libcrystal.a -levent -lrt -ldl -L/usr/lib -L/usr/local/lib
ar rcs libcounter.a libcounter.o
user1 ~/download/try/crystal_library (master) $ make test
cc test/counter_test.c ./libcounter.a /opt/crystal/share/crystal/src/ext/libcrystal.a -lgc -ldl -levent -lpcre -o counter_test
./libcounter.a(libcounter.o): In function `main':
/opt/crystal/share/crystal/src/crystal/main.cr:134: multiple definition of `main'
/tmp/ccowU1tv.o:counter_test.c:(.text+0x0): first defined here
/usr/bin/ld: cannot find -lgc
collect2: error: ld returned 1 exit status
Makefile:18: recipe for target 'counter_test' failed
make: *** [counter_test] Error 1

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.