angepasst an nversion
Some checks are pending
Build CPU miner / build (push) Waiting to run

This commit is contained in:
w12
2025-01-07 16:04:36 +01:00
5 changed files with 249 additions and 16 deletions

View File

@@ -1,14 +1,32 @@
<<<<<<< HEAD
AC_INIT([nolambocoin], [1.0])
=======
>>>>>>> b12eeead377cb6dddc74a57b520c4f3334d3e21f
AC_PREREQ([2.59c])
AC_CONFIG_SRCDIR([cpu-miner.c])
AC_INIT([nolambocoin-miner], [1.0])
AM_INIT_AUTOMAKE([foreign])
AC_CONFIG_SRCDIR([cpu-miner.c])
AC_CONFIG_HEADERS([cpuminer-config.h])
<<<<<<< HEAD
=======
# Füge die Makefile-Konfiguration hinzu
AC_CONFIG_FILES([Makefile
compat/Makefile
compat/jansson/Makefile
])
# Lade pkg-config Makros
PKG_PROG_PKG_CONFIG
>>>>>>> b12eeead377cb6dddc74a57b520c4f3334d3e21f
AM_MAINTAINER_MODE
EXTERNAL_CFLAGS="$CFLAGS"
<<<<<<< HEAD
# Check for jansson
PKG_CHECK_MODULES([JANSSON], [jansson], [], [AC_MSG_ERROR([jansson is required but not installed.])])
@@ -21,6 +39,8 @@ PKG_CHECK_MODULES([CURL], [libcurl], [], [AC_MSG_ERROR([libcurl is required but
AC_SUBST([CURL_CFLAGS])
AC_SUBST([CURL_LIBS])
=======
>>>>>>> b12eeead377cb6dddc74a57b520c4f3334d3e21f
# Checks for programs
AC_PROG_CC
AC_PROG_GCC_TRADITIONAL
@@ -49,6 +69,7 @@ AC_CHECK_DECLS([be32dec, le32dec, be32enc, le32enc], [],
AC_FUNC_ALLOCA
AC_CHECK_FUNCS([getopt_long])
<<<<<<< HEAD
# Define WS2_LIBS for Windows (set to empty for non-Windows platforms)
WS2_LIBS=""
case "$target_os" in
@@ -59,6 +80,27 @@ esac
AC_SUBST([WS2_LIBS])
# Platform detection
=======
# Pthread Flags
AC_CHECK_LIB([pthread], [pthread_create],
[PTHREAD_LIBS="-lpthread"],
[AC_MSG_ERROR([pthread library not found.])])
AC_SUBST([PTHREAD_LIBS])
# Ersetze AC_CHECK_FLAGS durch AC_COMPILE_IFELSE
AC_MSG_CHECKING([whether -pthread flag is supported])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([], [])],
[PTHREAD_CFLAGS="-pthread"],
[PTHREAD_CFLAGS=""])
AC_MSG_RESULT([$PTHREAD_CFLAGS])
AC_SUBST([PTHREAD_CFLAGS])
# WS2 Libraries (Windows)
WS2_LIBS=""
have_win32=false
# Plattform-Erkennung
>>>>>>> b12eeead377cb6dddc74a57b520c4f3334d3e21f
UNAME_S=`uname -s`
UNAME_M=`uname -m`
@@ -124,9 +166,30 @@ case "$UNAME_S" in
;;
esac
<<<<<<< HEAD
AC_CONFIG_FILES([
Makefile
compat/Makefile
compat/jansson/Makefile
])
=======
AM_CONDITIONAL([WANT_JANSSON], [true])
# Checks für libcurl
PKG_CHECK_MODULES([CURL], [libcurl >= 7.0], [],
[AC_MSG_ERROR([libcurl is required but not installed.])])
# Checks für jansson
PKG_CHECK_MODULES([JANSSON], [jansson >= 2.0], [],
[AC_MSG_ERROR([jansson is required but not installed.])])
AC_SUBST([JANSSON_CFLAGS])
AC_SUBST([JANSSON_LIBS])
AC_SUBST([CURL_CFLAGS])
AC_SUBST([CURL_LIBS])
AC_SUBST([PTHREAD_CFLAGS])
AC_SUBST([PTHREAD_LIBS])
AC_SUBST([WS2_LIBS])
>>>>>>> b12eeead377cb6dddc74a57b520c4f3334d3e21f
AC_OUTPUT