Fix Makefile
Stefan Bund [Thu, 25 Feb 2010 13:42:53 +0000 (14:42 +0100)]
Makefile

index 8d18970..7682371 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,3 +1,5 @@
+default: mapsectorsh
+
 ###########################################################################
 # Standard debian rules
 
@@ -32,9 +34,9 @@ $(CHANGELOGS): %:
        @(                                                                                       \
             version="$@"; version="$${version#$(CLOGDIR)/}";                                    \
            from="$${version%-*}"; version="$${version#*-}"; to="$$version";                     \
-           if [ "$$from" == "$$to" ]; then from=""; fi;                                         \
+           if [ "$$from" = "$$to" ]; then from=""; fi;                                  \
            release="unstable";                                                                  \
-           if [ "$$version" == "HEAD" ]; then                                                   \
+           if [ "$$version" = "HEAD" ]; then                                                    \
                version="`git describe --tag --match='v*' | sed -e 's/-/~/' -e 's/-/./g'`";      \
                release="UNRELEASED";                                                            \
            fi;                                                                                  \
@@ -64,7 +66,8 @@ prepare:: debian/changelog
 ###########################################################################
 ###########################################################################
 
-prepare::
+prepare:: lib/00_version.sh
+lib/00_version.sh:
        echo "version='`git describe --tag`'" >lib/00_version.sh
 clean::
        rm -f lib/00_version.sh
@@ -84,7 +87,7 @@ mapsectorsh: mapsector lib/00_version.sh $(wildcard lib/[0-9][0-9]_*.sh)
            done;                                               \
            sed -n -e '2,/^load$$/p' $<;                        \
            for script in $^; do                                \
-               if [ "$$script" == "$<" ]; then continue; fi;   \
+               if [ "$$script" = "$<" ]; then continue; fi;    \
                echo "#### $$script";                           \
                echo;                                           \
                cat $$script;                                   \