Changed cmake project to autotols

main
noah metz 2024-10-07 16:32:05 -06:00
parent 5ff2ffe7b7
commit 0e2fe46ca8
5 changed files with 37 additions and 197 deletions

@ -1,16 +0,0 @@
cmake_minimum_required(VERSION 3.11)
project(roleplay)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
set(RAYLIB_VERSION, 5.5)
find_package(raylib ${RAYLIB_VERSION} REQUIRED)
add_executable(${PROJECT_NAME} src/main.c)
target_link_libraries(${PROJECT_NAME} raylib)
if (APPLE)
target_link_libraries(${PROJECT_NAME} "-framework IOKit")
target_link_libraries(${PROJECT_NAME} "-framework Cocoa")
target_link_libraries(${PROJECT_NAME} "-framework OpenGL")
endif()

@ -1,181 +0,0 @@
# CMAKE generated file: DO NOT EDIT!
# Generated by "Unix Makefiles" Generator, CMake Version 3.30
# Default target executed when no arguments are given to make.
default_target: all
.PHONY : default_target
# Allow only one "make -f Makefile2" at a time, but pass parallelism.
.NOTPARALLEL:
#=============================================================================
# Special targets provided by cmake.
# Disable implicit rules so canonical targets will work.
.SUFFIXES:
# Disable VCS-based implicit rules.
% : %,v
# Disable VCS-based implicit rules.
% : RCS/%
# Disable VCS-based implicit rules.
% : RCS/%,v
# Disable VCS-based implicit rules.
% : SCCS/s.%
# Disable VCS-based implicit rules.
% : s.%
.SUFFIXES: .hpux_make_needs_suffix_list
# Command-line flag to silence nested $(MAKE).
$(VERBOSE)MAKESILENT = -s
#Suppress display of executed commands.
$(VERBOSE).SILENT:
# A target that is always out of date.
cmake_force:
.PHONY : cmake_force
#=============================================================================
# Set environment variables for the build.
# The shell in which to execute make rules.
SHELL = /bin/sh
# The CMake executable.
CMAKE_COMMAND = /opt/homebrew/Cellar/cmake/3.30.3/bin/cmake
# The command to remove a file.
RM = /opt/homebrew/Cellar/cmake/3.30.3/bin/cmake -E rm -f
# Escaping for special characters.
EQUALS = =
# The top-level source directory on which CMake was run.
CMAKE_SOURCE_DIR = /Users/noah/Code/roleplay/client
# The top-level build directory on which CMake was run.
CMAKE_BINARY_DIR = /Users/noah/Code/roleplay/client
#=============================================================================
# Targets provided globally by CMake.
# Special rule for the target edit_cache
edit_cache:
@$(CMAKE_COMMAND) -E cmake_echo_color "--switch=$(COLOR)" --cyan "Running CMake cache editor..."
/opt/homebrew/Cellar/cmake/3.30.3/bin/ccmake -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)
.PHONY : edit_cache
# Special rule for the target edit_cache
edit_cache/fast: edit_cache
.PHONY : edit_cache/fast
# Special rule for the target rebuild_cache
rebuild_cache:
@$(CMAKE_COMMAND) -E cmake_echo_color "--switch=$(COLOR)" --cyan "Running CMake to regenerate build system..."
/opt/homebrew/Cellar/cmake/3.30.3/bin/cmake --regenerate-during-build -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR)
.PHONY : rebuild_cache
# Special rule for the target rebuild_cache
rebuild_cache/fast: rebuild_cache
.PHONY : rebuild_cache/fast
# The main all target
all: cmake_check_build_system
$(CMAKE_COMMAND) -E cmake_progress_start /Users/noah/Code/roleplay/client/CMakeFiles /Users/noah/Code/roleplay/client//CMakeFiles/progress.marks
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 all
$(CMAKE_COMMAND) -E cmake_progress_start /Users/noah/Code/roleplay/client/CMakeFiles 0
.PHONY : all
# The main clean target
clean:
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 clean
.PHONY : clean
# The main clean target
clean/fast: clean
.PHONY : clean/fast
# Prepare targets for installation.
preinstall: all
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 preinstall
.PHONY : preinstall
# Prepare targets for installation.
preinstall/fast:
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 preinstall
.PHONY : preinstall/fast
# clear depends
depend:
$(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 1
.PHONY : depend
#=============================================================================
# Target rules for targets named roleplay
# Build rule for target.
roleplay: cmake_check_build_system
$(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 roleplay
.PHONY : roleplay
# fast build rule for target.
roleplay/fast:
$(MAKE) $(MAKESILENT) -f CMakeFiles/roleplay.dir/build.make CMakeFiles/roleplay.dir/build
.PHONY : roleplay/fast
src/main.o: src/main.c.o
.PHONY : src/main.o
# target to build an object file
src/main.c.o:
$(MAKE) $(MAKESILENT) -f CMakeFiles/roleplay.dir/build.make CMakeFiles/roleplay.dir/src/main.c.o
.PHONY : src/main.c.o
src/main.i: src/main.c.i
.PHONY : src/main.i
# target to preprocess a source file
src/main.c.i:
$(MAKE) $(MAKESILENT) -f CMakeFiles/roleplay.dir/build.make CMakeFiles/roleplay.dir/src/main.c.i
.PHONY : src/main.c.i
src/main.s: src/main.c.s
.PHONY : src/main.s
# target to generate assembly for a file
src/main.c.s:
$(MAKE) $(MAKESILENT) -f CMakeFiles/roleplay.dir/build.make CMakeFiles/roleplay.dir/src/main.c.s
.PHONY : src/main.c.s
# Help Target
help:
@echo "The following are some of the valid targets for this Makefile:"
@echo "... all (the default if no target is provided)"
@echo "... clean"
@echo "... depend"
@echo "... edit_cache"
@echo "... rebuild_cache"
@echo "... roleplay"
@echo "... src/main.o"
@echo "... src/main.i"
@echo "... src/main.s"
.PHONY : help
#=============================================================================
# Special targets to cleanup operation of make.
# Special rule to run CMake to check the build system integrity.
# No rule that depends on this can have commands that come from listfiles
# because they might be regenerated.
cmake_check_build_system:
$(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 0
.PHONY : cmake_check_build_system

@ -0,0 +1,4 @@
bin_PROGRAMS = roleplay
roleplay_SOURCES = src/main.c
roleplay_LDADD = @RAYLIB_LIBS@ @ZMQ_LIBS@
roleplay_CFLAGS = @RAYLIB_CFLAGS@ @ZMQ_CFLAGS@

@ -0,0 +1,33 @@
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.00])
AC_INIT([roleplay], [v1.0])
AC_CONFIG_SRCDIR([src/main.c])
AC_CONFIG_AUX_DIR([config])
# Initialize automake
AM_INIT_AUTOMAKE([-Wall -Werror foreign subdir-objects])
# Checks for programs.
AC_PROG_CC
# Checks for libraries.
PKG_CHECK_MODULES([RAYLIB], [raylib])
AC_SUBST([RAYLIB_CFLAGS])
AC_SUBST([RAYLIB_LIBS])
PKG_CHECK_MODULES([ZMQ], [libzmq])
AC_SUBST([ZMQ_CFLAGS])
AC_SUBST([ZMQ_LIBS])
# Checks for header files.
AC_CHECK_HEADER([stdint.h])
# Checks for typedefs, structures, and compiler characteristics.
# Checks for library functions.
AC_CONFIG_FILES([Makefile])
AC_OUTPUT

Binary file not shown.