diff options
-rw-r--r-- | crawl-ref/source/makefile_tiles.unix | 2 | ||||
-rw-r--r-- | crawl-ref/source/rltiles/tool/tile_list_processor.cc | 9 | ||||
-rw-r--r-- | crawl-ref/source/tilebuf.h | 1 |
3 files changed, 6 insertions, 6 deletions
diff --git a/crawl-ref/source/makefile_tiles.unix b/crawl-ref/source/makefile_tiles.unix index f364506d7b..0fd7fdebbb 100644 --- a/crawl-ref/source/makefile_tiles.unix +++ b/crawl-ref/source/makefile_tiles.unix @@ -125,7 +125,7 @@ LIB = -L$(LUASRC) -l$(LUALIB) $(LIBDBM) -lpng $(SDL_LDFLAGS) -lGL -lGLU -lSDL_im INCLUDES := $(INCLUDES) -Iutil -I. -I$(LUASRC) $(EXTRA_INCLUDES) $(PNG_INCLUDE) $(FREETYPE_INCLUDE) -CFWARN := -Wall -Wwrite-strings -Wshadow -pedantic +CFWARN := -Wall -Wwrite-strings -Wshadow -pedantic -Wno-parentheses CFOTHERS := -fsigned-char -D$(OS_TYPE) $(EXTRA_FLAGS) -DCLUA_BINDINGS diff --git a/crawl-ref/source/rltiles/tool/tile_list_processor.cc b/crawl-ref/source/rltiles/tool/tile_list_processor.cc index 4f43f20793..35df77d221 100644 --- a/crawl-ref/source/rltiles/tool/tile_list_processor.cc +++ b/crawl-ref/source/rltiles/tool/tile_list_processor.cc @@ -499,7 +499,7 @@ bool tile_list_processor::write_data() { if (m_name == "") { - fprintf(stderr, "Error: can't write data with no %name specified.\n"); + fprintf(stderr, "Error: can't write data with no %%name specified.\n"); return false; } @@ -649,7 +649,7 @@ bool tile_list_processor::write_data() fprintf(fp, "#include <map>\n"); fprintf(fp, "#include <string>\n"); fprintf(fp, "#include <assert.h>\n"); - fprintf(fp, "using namespace std;\n"); + fprintf(fp, "using namespace std;\n\n"); fprintf(fp, "int _tile_%s_count[%s - %s] =\n{\n", lcname.c_str(), max.c_str(), m_start_value.c_str()); @@ -736,8 +736,7 @@ bool tile_list_processor::write_data() fprintf(fp, "tile_%s_map::tile_%s_map()\n" - "{\n" - " map<string, int>::iterator itr = begin();\n", + "{\n", lcname.c_str(), lcname.c_str()); for (unsigned int i = 0; i < m_page.m_tiles.size(); i++) @@ -751,7 +750,7 @@ bool tile_list_processor::write_data() for (unsigned int c = 0; c < enumname.size(); c++) lcenum[c] = std::tolower(enumname[c]); - fprintf(fp, " insert(itr, map<string, int>::value_type(\"%s\", %d + %s));\n", + fprintf(fp, " insert(map<string, int>::value_type(\"%s\", %d + %s));\n", lcenum.c_str(), i, m_start_value.c_str()); } diff --git a/crawl-ref/source/tilebuf.h b/crawl-ref/source/tilebuf.h index f1281ec977..6b0ae7eab4 100644 --- a/crawl-ref/source/tilebuf.h +++ b/crawl-ref/source/tilebuf.h @@ -13,6 +13,7 @@ class formatted_string; class GenericTexture; class TilesTexture; +#include <string> #include <vector> struct VColour |