From 07c4b6c968f19822433fc4f3d02146bce2991607 Mon Sep 17 00:00:00 2001 From: Wolfgang Thaller Date: Thu, 16 Jul 2015 02:29:30 +0200 Subject: [PATCH] remove HelloWorld example from Console subdirectory --- CMakeLists.txt | 1 + Console/CMakeLists.txt | 7 +------ Console/hello.c | 28 ---------------------------- HelloWorld/CMakeLists.txt | 9 +++++---- HelloWorld/Makefile | 4 ++++ 5 files changed, 11 insertions(+), 38 deletions(-) delete mode 100644 Console/hello.c diff --git a/CMakeLists.txt b/CMakeLists.txt index 94eae1699a..9c003944d1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -25,6 +25,7 @@ add_subdirectory(libretro) link_directories(${CMAKE_CURRENT_BINARY_DIR}/libretro) add_subdirectory(Console) +add_subdirectory(HelloWorld) add_subdirectory(TestApps) add_subdirectory(Raytracer) add_subdirectory(Launcher) diff --git a/Console/CMakeLists.txt b/Console/CMakeLists.txt index 8b7dde89ab..a67180fa85 100644 --- a/Console/CMakeLists.txt +++ b/Console/CMakeLists.txt @@ -22,13 +22,8 @@ add_library(RetroConsole Console.cc Console.h MacUtils.h - InitConsole.cc + InitConsole.cc ) install(TARGETS RetroConsole DESTINATION lib) -add_application(HelloWorld - hello.c - CONSOLE - ) - diff --git a/Console/hello.c b/Console/hello.c deleted file mode 100644 index 1dbd3ac56d..0000000000 --- a/Console/hello.c +++ /dev/null @@ -1,28 +0,0 @@ -/* - Copyright 2014 Wolfgang Thaller. - - This file is part of Retro68. - - Retro68 is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - Retro68 is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with Retro68. If not, see . -*/ - -#include - -int main(int argc, char** argv) -{ - printf("Hello, world.\n"); - printf("\n(Press Return)\n"); - getchar(); - return 0; -} diff --git a/HelloWorld/CMakeLists.txt b/HelloWorld/CMakeLists.txt index c810f7a018..6b71e5f3e2 100644 --- a/HelloWorld/CMakeLists.txt +++ b/HelloWorld/CMakeLists.txt @@ -1,7 +1,8 @@ -# cmake \ -# -DCMAKE_TOOLCHAIN_FILE=$SRC/retro68.toolchain.cmake \ -# -DRETRO68_ROOT=$PREFIX \ -# -DCMAKE_BUILD_TYPE=Release +# HOW TO BUILD USING CMAKE as a standalone project: +# mkdir build +# cd build +# cmake .. -DCMAKE_TOOLCHAIN_FILE=path/to/Retro68-build/toolchain/cmake/retro68.toolchain.cmake +# make cmake_minimum_required(VERSION 2.8) diff --git a/HelloWorld/Makefile b/HelloWorld/Makefile index b62121380e..f39873339b 100644 --- a/HelloWorld/Makefile +++ b/HelloWorld/Makefile @@ -13,3 +13,7 @@ HelloWorld.bin HelloWorld.APPL HelloWorld.dsk: HelloWorld.flt HelloWorld.flt: hello.o $(CXX) $< -o $@ $(LDFLAGS) # C++ used for linking because RetroConsole needs it + +.PHONY: clean +clean: + rm -f HelloWorld.bin HelloWorld.APPL HelloWorld.dsk HelloWorld.flt HelloWorld.flt.gdb hello.o