Advertisement Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Community Reputation

122 Neutral

About grady

  • Rank
  1. grady

    Strange GCC Issue

    I'm not an expert, but this is what I do to automatically create a makefile for my small projects. The file below would be called The line in the 'makefile' target that calls the compiler with the -M option does all of the magic. 'gcc -M source.cpp' will barf a makefile-syntax-friendly list of header files that source.cpp depends on. I found this out from O'Reilly's "Managing Projects with Make" book. #to recreate the makefile type 'make -f makefile AUTO=headers' INCLUDE=-I /usr/incl (truncated) SOURCES=$(OBJS:.o=.cpp) terrain.cpp game : $(OBJS) $(CXX) $(OBJS) $(INCLUDE) $(LIBS) -pg -o $@ terrain : $(TERRAINOBJS) $(CXX) $(TERRAINOBJS) $(INCLUDE) $(LIBS) -pg -o $@ clean: rm core* *.o game makefile : $(AUTO) cp $@ $(CXX) $(INCLUDE) -M $(SOURCES) >> $@ headers:
  2. Here is a how-to on loading functions and classes from shared objects at runtime.
  • Advertisement

Important Information

By using, you agree to our community Guidelines, Terms of Use, and Privacy Policy. is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!