• Create Account

Need scary sound effects or creepy audio loops for your next horror-themed game? Check out Highscore Vol.3 - The Horror Edition in our marketplace. 50 sounds and 10 loops for only $9.99! # I think I compiled chipmunk-physics engine with MinGW No replies to this topic ### #1farmdve Members - Reputation: 194 Like 0Likes Like Posted 25 August 2013 - 04:59 AM I didn't like it that it used Visual Studio, so I decided to give it ago and made this makefile CC=gcc LIBS= PROGNAME=chipmunk CFLAGS= -c -std=c99 -I../include/chipmunk -I../include/chipmunk/constraints SRCS= ../src/chipmunk.c \ ../src/cpArbiter.c \ ../src/cpArray.c \ ../src/cpBB.c \ ../src/cpBBTree.c \ ../src/cpBody.c \ ../src/cpCollision.c \ ../src/cpHashSet.c \ ../src/cpPolyShape.c \ ../src/cpShape.c \ ../src/cpSpace.c \ ../src/cpSpaceComponent.c \ ../src/cpSpaceHash.c \ ../src/cpSpaceQuery.c \ ../src/cpSpaceStep.c \ ../src/cpSpatialIndex.c \ ../src/cpSweep1D.c \ ../src/cpVect.c \ ../src/constraints/cpConstraint.c \ ../src/constraints/cpDampedRotarySpring.c \ ../src/constraints/cpDampedSpring.c \ ../src/constraints/cpGearJoint.c \ ../src/constraints/cpGrooveJoint.c \ ../src/constraints/cpPinJoint.c \ ../src/constraints/cpPivotJoint.c \ ../src/constraints/cpRatchetJoint.c \ ../src/constraints/cpRotaryLimitJoint.c \ ../src/constraints/cpSimpleMotor.c \ ../src/constraints/cpSlideJoint.c OBJS =$(SRCS:.c=.o)

all: $(OBJS)$(CC) $^$(CFLAGS) $(LIBS) ar cr lib$(PROGNAME).a \$(OBJS)


Place this file in a newly created mingw folder in the root folder of chipmunk-physics-6.1.5(or whichever version is new). It will then create libchipmunk.a, now I am not an expert, but if it compiles I assume it works, I cannot compile the demos as they used GLUT for the Windowing system and that doesn't have a MinGW port, plus I will be using SDL. However, I did compile the demos manually(without ChimpmunkDemo.c) by using libchimpmunk.a and it compiled without warnings and only two with -Wextra and -Wall.