{"id":15967610,"url":"https://github.com/tinchodias/pharo-chipmunk2d","last_synced_at":"2025-04-04T13:42:33.648Z","repository":{"id":221246374,"uuid":"240353822","full_name":"tinchodias/pharo-chipmunk2D","owner":"tinchodias","description":"Pharo FFI bindings to Chipmunk2D library","archived":false,"fork":false,"pushed_at":"2024-02-08T18:39:23.000Z","size":82,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-09T23:27:18.264Z","etag":null,"topics":["ffi","pharo"],"latest_commit_sha":null,"homepage":"","language":"Smalltalk","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tinchodias.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-02-13T20:24:58.000Z","updated_at":"2024-02-08T18:33:24.000Z","dependencies_parsed_at":null,"dependency_job_id":"d70430ba-5163-4306-a7f3-0a2d4582187d","html_url":"https://github.com/tinchodias/pharo-chipmunk2D","commit_stats":null,"previous_names":["tinchodias/pharo-chipmunk2d"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tinchodias%2Fpharo-chipmunk2D","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tinchodias%2Fpharo-chipmunk2D/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tinchodias%2Fpharo-chipmunk2D/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tinchodias%2Fpharo-chipmunk2D/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tinchodias","download_url":"https://codeload.github.com/tinchodias/pharo-chipmunk2D/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247188730,"owners_count":20898572,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ffi","pharo"],"created_at":"2024-10-07T18:40:30.268Z","updated_at":"2025-04-04T13:42:33.631Z","avatar_url":"https://github.com/tinchodias.png","language":"Smalltalk","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Pharo Chipmunk2D bindings\n\nPharo FFI bindings to [Chipmunk2D](http://chipmunk-physics.net/).\n\n⚠️ Warning: Not ready for production: API coverage is very incomplete and must check for memory leaks ⚠️\n\nChipmunk2D is a simple, lightweight, fast and portable 2D rigid body physics library written in C. It’s licensed under the unrestrictive, OSI approved MIT license. Hundreds of shipping games have chosen Chipmunk because of the high quality, speed, and accuracy of its 2D physics simulations. \n\n## Install\n\nThere are two steps that may be done in parallel. One if building the C library, and second, get Pharo and load the bindings.\n\n**Build C library**\n\nThe objective of this step is to have the library in a directory named Chipmunk2D in the image directory.\n\nFirst, git clone and checkout a specific commit:\n```bash\ngit clone git@github.com:slembcke/Chipmunk2D.git\ncd Chipmunk2D\ngit checkout d0239ef4599b3688a5a336373f7d0a68426414ba\n```\nWhy that commit? at the moment of writing this README, the most recent tag in the chipmunk repo is too old (7.0.3) and build fails.\n\nSecond, cd to the library root directory and execute in command-line:\n```bash\ncmake .\nmake\n```\n\nIt should show something like:\n```\n[ 34%] Linking C static library libchipmunk.a\n[ 34%] Built target chipmunk_static\n...\n[ 69%] Linking C shared library libchipmunk.dylb\n[ 69%] Built target chipmunk\n...\n[100%] Linking C executable chipmunk_demos\n[100%] Built target chipmunk_demos\n```\n\nYou can run the original library demos with `./demo/chipmunk_demos`. Press keys A to Z to select between scenes.\n\n\n**Build Pharo bindings**\n\nEvaluate in Pharo 11:\n\n~~~Smalltalk\nMetacello new \n  baseline: 'Chipmunk2D'; \n  repository: 'github://tinchodias/pharo-chipmunk2D/';\n  load.\n~~~\n\nEnsure in `CpLibrary` class that whether `macModuleName` or `unixModuleName` point to the right file.\n\n## History\n\nThe origin of this code dates back to https://github.com/cldm/pharo-storm that also comes from Esteban Lorenzano's Storm repostory in the old SmalltalkHub.\n\n## License\n\nThis code is licensed under the [MIT license](./LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftinchodias%2Fpharo-chipmunk2d","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftinchodias%2Fpharo-chipmunk2d","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftinchodias%2Fpharo-chipmunk2d/lists"}