Browse Source

Clean up readme a bit, add a note about running automagic from the root, and clean automagic up by making it slightly more verbose, and letting it check it's being run in the right directory (see issue #698)

Bart van Strien 12 years ago
parent
commit
138fe49e35
2 changed files with 31 additions and 10 deletions
  1. 24 6
      platform/unix/automagic
  2. 7 4
      readme.md

+ 24 - 6
platform/unix/automagic

@@ -1,10 +1,19 @@
 #!/bin/bash
 #!/bin/bash
 
 
+log() {
+	echo "[automagic] " $@
+}
+
 die() {
 die() {
-	echo "Fatal: "$@
+	log "Fatal: "$@
 	exit 1
 	exit 1
 }
 }
 
 
+if [[ ! -d platform/unix ]]; then
+	log "Can't find the 'plaform/unix' folder, make sure you run this from the root of the repository."
+	exit 1
+fi
+
 AUTOHEADER=$(which autoheader)
 AUTOHEADER=$(which autoheader)
 AUTOCONF=$(which autoconf)
 AUTOCONF=$(which autoconf)
 LIBTOOLIZE=$(which libtoolize)
 LIBTOOLIZE=$(which libtoolize)
@@ -26,21 +35,30 @@ automagic() {
 		exit 1
 		exit 1
 	fi
 	fi
 
 
+	log "Running autoheader..." >&2
 	${AUTOHEADER} 2>&1 || return 1 # Gimmie config.h.in
 	${AUTOHEADER} 2>&1 || return 1 # Gimmie config.h.in
+
+	log "Running libtoolize..." >&2
 	${LIBTOOLIZE} --force 2>&1 || return 1
 	${LIBTOOLIZE} --force 2>&1 || return 1
+
+	log "Running aclocal..." >&2
 	${ACLOCAL} 2>&1 || return 1
 	${ACLOCAL} 2>&1 || return 1
+
+	log "Running autoconf..." >&2
 	${AUTOCONF} 2>&1 || return 1
 	${AUTOCONF} 2>&1 || return 1
+
+	log "Running automake..." >&2
 	${AUTOMAKE} -a 2>&1 || return 1
 	${AUTOMAKE} -a 2>&1 || return 1
 }
 }
 
 
 if [[ $1 == "-d" ]]; then
 if [[ $1 == "-d" ]]; then
-	automagic
+	automagic 2>&1
 else
 else
-	automagic > /dev/null
+	(automagic > /dev/null) 2>&1
 fi
 fi
-if [ $? -eq 1 ]; then
-	echo "Failed, please contact the developers."
+if [[ $? -eq 1 ]]; then
+	log "Failed, please contact the developers."
 	exit 1
 	exit 1
 else
 else
-	echo "Success, carry on configuring."
+	log "Success, carry on configuring."
 fi
 fi

+ 7 - 4
readme.md

@@ -13,7 +13,11 @@ Compilation
 Use the project files for Visual Studio 2010 located in the platform dir.
 Use the project files for Visual Studio 2010 located in the platform dir.
 
 
 ###*nix
 ###*nix
-Run platform/unix/automagic, then run ./configure and make.
+Run `platform/unix/automagic` from the repository root, then run ./configure and make.
+
+	$ platform/unix/automagic
+	$ ./configure
+	$ make
 
 
 ###OSX
 ###OSX
 Use the XCode project in platform/macosx.
 Use the XCode project in platform/macosx.
@@ -37,10 +41,9 @@ and there's a ppa for ubuntu, [ppa:bartbes/love-stable][stableppa].
 
 
 There are also unstable/nightly builds:
 There are also unstable/nightly builds:
 
 
-- For windows they are located [here][winbuilds].
+- Most can be found [here][builds].
 - For ubuntu linux they are in [ppa:bartbes/love-unstable][unstableppa]
 - For ubuntu linux they are in [ppa:bartbes/love-unstable][unstableppa]
 - For arch linux there's [love-hg][aur] in the AUR.
 - For arch linux there's [love-hg][aur] in the AUR.
-- For other linuxes and OSX there are currently no official builds.
 
 
 Dependencies
 Dependencies
 ------------
 ------------
@@ -61,7 +64,7 @@ Dependencies
 [forums]: http://love2d.org/forums
 [forums]: http://love2d.org/forums
 [irc]: irc://irc.oftc.net/love
 [irc]: irc://irc.oftc.net/love
 [dependencies]: http://love2d.org/sdk
 [dependencies]: http://love2d.org/sdk
-[winbuilds]: http://love2d.org/builds
+[builds]: http://love2d.org/builds
 [stableppa]: https://launchpad.net/~bartbes/+archive/love-stable
 [stableppa]: https://launchpad.net/~bartbes/+archive/love-stable
 [unstableppa]: https://launchpad.net/~bartbes/+archive/love-unstable
 [unstableppa]: https://launchpad.net/~bartbes/+archive/love-unstable
 [aur]: http://aur.archlinux.org/packages.php?ID=35279
 [aur]: http://aur.archlinux.org/packages.php?ID=35279