Browse Source

Explicitly link in ws2_32 on the windows build and update README file on how to compile successfully on windows.

nfactor-troky
Con Kolivas 13 years ago
parent
commit
f062765c94
  1. 2
      Makefile.am
  2. 6
      README
  3. 3
      configure.ac

2
Makefile.am

@ -26,7 +26,7 @@ cgminer_SOURCES = elist.h miner.h compat.h bench_block.h \ @@ -26,7 +26,7 @@ cgminer_SOURCES = elist.h miner.h compat.h bench_block.h \
phatk110816.cl poclbm110816.cl
cgminer_LDFLAGS = $(PTHREAD_FLAGS)
cgminer_LDADD = @LIBCURL_LIBS@ @JANSSON_LIBS@ @PTHREAD_LIBS@ @OPENCL_LIBS@ @NCURSES_LIBS@ @PDCURSES_LIBS@ lib/libgnu.a ccan/libccan.a
cgminer_LDADD = @LIBCURL_LIBS@ @JANSSON_LIBS@ @PTHREAD_LIBS@ @OPENCL_LIBS@ @NCURSES_LIBS@ @PDCURSES_LIBS@ @WS2_LIBS@ lib/libgnu.a ccan/libccan.a
cgminer_CPPFLAGS = @LIBCURL_CPPFLAGS@ -I$(top_builddir)/lib -I$(top_srcdir)/lib
if HAVE_x86_64

6
README

@ -56,13 +56,15 @@ Basic WIN32 build instructions (on Fedora 13; requires mingw32): @@ -56,13 +56,15 @@ Basic WIN32 build instructions (on Fedora 13; requires mingw32):
./mknsis.sh
Native WIN32 build instructions (on mingw32, on windows):
Install AMD APP sdk, latest version
Install the Microsoft platform SDK
Install AMD APP sdk, latest version (only if you want GPU mining)
(Do NOT install the ati amd sdk if you are on nvidia)
Install mingw32
Install libcurl, copy libcurl.m4 into /mingw/share/aclocal
Install pkg-config, copy pkg.m4 into /mingw/share/aclocal
Run:
autoreconf -fvi
CFLAGS="-O2 -Wall -msse2 -I<path to AMD APP include>" LDFLAGS="-L<path to AMD APP lib/x86>" ./configure
CFLAGS="-O2 -msse2" ./configure
make
Usage instructions: Run "cgminer --help" to see options.

3
configure.ac

@ -28,6 +28,7 @@ AC_FUNC_ALLOCA @@ -28,6 +28,7 @@ AC_FUNC_ALLOCA
have_win32=false
PTHREAD_FLAGS="-pthread"
OPENCL_FLAGS="-lOpenCL"
WS2_LIBS=""
case $target in
x86_64-*)
@ -43,6 +44,7 @@ case $target in @@ -43,6 +44,7 @@ case $target in
have_x86_64=false
have_win32=true
PTHREAD_FLAGS=""
WS2_LIBS="-lws2_32"
;;
*-*-darwin*)
OPENCL_FLAGS="-framework OpenCL"
@ -167,6 +169,7 @@ AC_SUBST(PTHREAD_FLAGS) @@ -167,6 +169,7 @@ AC_SUBST(PTHREAD_FLAGS)
AC_SUBST(PTHREAD_LIBS)
AC_SUBST(NCURSES_LIBS)
AC_SUBST(PDCURSES_LIBS)
AC_SUBST(WS2_LIBS)
AC_CONFIG_FILES([
Makefile

Loading…
Cancel
Save