Skip to content

Commit

Permalink
Merge pull request #13239 from Rechi/cleanupTexturePacker
Browse files Browse the repository at this point in the history
[cleanup][TexturePacker] remove PlatformDefs include
  • Loading branch information
Rechi committed Dec 23, 2017
2 parents 8e57c10 + ccf5f5b commit e13685a
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 38 deletions.
2 changes: 0 additions & 2 deletions tools/depends/native/TexturePacker/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,6 @@ target_include_directories(TexturePacker
${JPEG_INCLUDE_DIR}
${GIF_INCLUDE_DIR}
${CMAKE_SOURCE_DIR}/xbmc
${CMAKE_SOURCE_DIR}/xbmc/${PLATFORM_DIR}
${CMAKE_SOURCE_DIR}/lib
${CMAKE_CURRENT_SOURCE_DIR}/src
${CMAKE_CURRENT_SOURCE_DIR}/src/decoder)
target_link_libraries(TexturePacker
Expand Down
2 changes: 0 additions & 2 deletions tools/depends/native/TexturePacker/src/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,8 @@ AM_CXXFLAGS = $(AM_CFLAGS) -std=c++0x
AM_CPPFLAGS = \
-I. \
-I./decoder \
-I@KODI_SRC_DIR@/lib \
-I@KODI_SRC_DIR@/xbmc \
-I@KODI_SRC_DIR@/xbmc/guilib \
-I@KODI_SRC_DIR@/xbmc/platform/linux \
@CPPFLAGS@

AM_LDFLAGS = @LIBS@ @STATIC_FLAG@
Expand Down
5 changes: 3 additions & 2 deletions tools/depends/native/TexturePacker/src/TexturePacker.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@

#ifdef TARGET_WINDOWS
#include <sys/types.h>
#include <sys/stat.h>
#define __STDC_FORMAT_MACROS
#include <cinttypes>
#define platform_stricmp _stricmp
#else
#define platform_stricmp stricmp
#include <inttypes.h>
#define platform_stricmp strcasecmp
#endif
#include <cerrno>
#include <dirent.h>
Expand All @@ -45,6 +45,7 @@
#endif

#include <lzo/lzo1x.h>
#include <sys/stat.h>

using namespace std;

Expand Down
10 changes: 4 additions & 6 deletions tools/depends/native/TexturePacker/src/cmdlineargs.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@
*/

#ifdef TARGET_POSIX
#include "PlatformDefs.h"
#include "xwinapi.h"
typedef LPSTR PSZ;
char* GetCommandLine();
#define _snprintf snprintf
#else
#include <windows.h>
Expand All @@ -39,7 +37,7 @@ class CmdLineArgs : public std::vector<char*>
{
// Save local copy of the command line string, because
// ParseCmdLine() modifies this string while parsing it.
PSZ cmdline = GetCommandLine();
char* cmdline = GetCommandLine();
m_cmdline = new char [strlen (cmdline) + 1];
if (m_cmdline)
{
Expand Down Expand Up @@ -87,7 +85,7 @@ class CmdLineArgs : public std::vector<char*>
}

private:
PSZ m_cmdline; // the command line string
char* m_cmdline; // the command line string

////////////////////////////////////////////////////////////////////////////////
// Parse m_cmdline into individual tokens, which are delimited by spaces. If a
Expand All @@ -103,7 +101,7 @@ class CmdLineArgs : public std::vector<char*>
QUOTE = '\"' };

bool bInQuotes = false;
PSZ pargs = m_cmdline;
char* pargs = m_cmdline;

while (*pargs)
{
Expand Down
26 changes: 0 additions & 26 deletions tools/depends/native/TexturePacker/src/xwinapi.h

This file was deleted.

0 comments on commit e13685a

Please sign in to comment.