Skip to content

Commit

Permalink
Code cleanup and binary removal (#3793)
Browse files Browse the repository at this point in the history
  • Loading branch information
undef21 authored Jul 4, 2021
1 parent 9908c9e commit 9d977c8
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 20 deletions.
4 changes: 2 additions & 2 deletions src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ LIBS := -pthread -lz
CFLAGS_TP := $(CFLAGS)
CXXFLAGS_TP := $(CXXFLAGS)

# Add -Wconversion -Wsign-conversion -Weffc++ -Woverloaded-virtual flags back once we fix all other warnings!
CFLAGS := $(CXXFLAGS) -Wall -Wextra -Wpedantic -Wfloat-conversion -Wshadow -Wfloat-equal -Wredundant-decls -Wdouble-promotion -Wunused -Wuninitialized -Wextra-semi
# Add -Wconversion -Wsign-conversion -Weffc++ -Woverloaded-virtual -Wextra-semi flags back once we fix all other warnings!
CFLAGS := $(CXXFLAGS) -Wall -Wextra -Wpedantic -Wfloat-conversion -Wshadow -Wfloat-equal -Wredundant-decls -Wdouble-promotion -Wunused -Wuninitialized

ifdef FHEROES2_STRICT_COMPILATION
CFLAGS := $(CFLAGS) -Werror
Expand Down
Binary file removed src/dist/fheroes2
Binary file not shown.
17 changes: 0 additions & 17 deletions src/engine/system.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -211,23 +211,6 @@ const char * System::GetEnvironment( const char * name )
#endif
}

int System::SetEnvironment( const char * name, const char * value )
{
#if defined( __MINGW32__ ) || defined( _MSC_VER )
std::string str( std::string( name ) + "=" + std::string( value ) );
#if SDL_VERSION_ATLEAST( 2, 0, 0 )
return _putenv( str.c_str() );
#else
// SDL 1.2.12 (char *)
return SDL_putenv( &str[0] );
#endif
#elif defined( __SWITCH__ ) || defined( FHEROES2_VITA )
return SDL_setenv( name, value, 1 );
#else
return setenv( name, value, 1 );
#endif
}

void System::SetLocale( int category, const char * locale )
{
#if defined( ANDROID ) || defined( __APPLE__ ) || defined( __clang__ )
Expand Down
1 change: 0 additions & 1 deletion src/engine/system.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@

namespace System
{
int SetEnvironment( const char * name, const char * value );
const char * GetEnvironment( const char * name );

int MakeDirectory( const std::string & );
Expand Down
1 change: 1 addition & 0 deletions src/fheroes2/agg/bin_info.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
#ifndef H2BIN_FRM_H
#define H2BIN_FRM_H

#include <cstddef>
#include <vector>

#include "math_base.h"
Expand Down

0 comments on commit 9d977c8

Please sign in to comment.