Skip to content
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

MacOS support #9

Closed
adxBRudolph opened this issue Jan 28, 2015 · 2 comments
Closed

MacOS support #9

adxBRudolph opened this issue Jan 28, 2015 · 2 comments

Comments

@adxBRudolph
Copy link

Running Go 1.4.1 on Mac OS 10.7.5.

I get the following error trying to get/build:

go get github.com/valyala/ybc/libs/go/memcache

github.com/valyala/ybc/bindings/go/ybc

In file included from /usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1:
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/platform.h:242:4: error: #error "unsupported platform"
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_hash_get':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:57: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_item_skiplist_init':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:292: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_item_skiplist_destroy':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:312: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_item_skiplist_get_prevs':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:339: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_item_skiplist_add':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:356: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_item_skiplist_del':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:380: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_item_skiplist_relocate':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:396: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_map_lookup_slot_index':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1014: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: At top level:
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1408: error: field 'stop_event' has incomplete type
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1413: error: field 'sync_thread' has incomplete type
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_de_init':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1626: error: dereferencing pointer to incomplete type
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1630: error: invalid use of undefined type 'struct p_lock'
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1632: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1633: error: invalid use of undefined type 'struct p_lock'
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_de_destroy':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1655: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1657: error: invalid use of undefined type 'struct p_lock'
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_de_item_register':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1716: error: invalid use of undefined type 'struct p_lock'
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1728: error: invalid use of undefined type 'struct p_lock'
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: At top level:
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1839: error: field 'lock' has incomplete type
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1840: error: field 'index_file' has incomplete type
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:1841: error: field 'storage_file' has incomplete type
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'm_cluster_close_caches':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:2435: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'ybc_cluster_open':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:2468: error: 'for' loop initial declaration used outside C99 mode
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c: In function 'ybc_cluster_clear':
/usr/local/go/bin/src/github.com/valyala/ybc/bindings/go/ybc/ybc.c:2543: error: 'for' loop initial declaration used outside C99 mode

@adxBRudolph
Copy link
Author

So I see in platform.h that only linux is supported. Any chance to add support for MAC OS X?

@valyala valyala changed the title Error Building MacOS support Mar 5, 2015
@valyala
Copy link
Owner

valyala commented Mar 5, 2015

Closing this bug, since it duplicates #10 . In short - currently YBC has no MacOS support, but it can be easily added by MacOS programmers by following guides at #10 . In short, just one small file with os-specific stuff must be written. I cannot implement it myself, since I have no access to MacOS at the moment.

@valyala valyala closed this as completed Mar 5, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants