fix upstream urls
[nestedvm.git] / upstream / Makefile
index 194c05a..3841290 100644 (file)
@@ -6,7 +6,7 @@ url_gcc-core = http://mirrors.rcn.net/pub/sourceware/gcc/releases/gcc-$(version_
 url_gcc-c++ = http://mirrors.rcn.net/pub/sourceware/gcc/releases/gcc-$(version_gcc)/gcc-g++-$(version_gcc).tar.gz
 url_gcc-g77 = http://mirrors.rcn.net/pub/sourceware/gcc/releases/gcc-$(version_gcc)/gcc-g77-$(version_gcc).tar.gz
 
-patches_gcc = gcc-fixes.patch gcc-fdata-sections-bss.patch
+patches_gcc = gcc-fixes.patch gcc-fdata-sections-bss.patch gcc-64bitclean.patch
 
 configure_gcc = --target=mips-unknown-elf --disable-threads --with-gnu-ld --with-gnu-as --with-newlib=yes --enable-sjlj-exceptions --enable-languages="c"
 configure_gcc_step2 = $(configure_gcc) --enable-languages="c,c++,f77"
@@ -31,6 +31,10 @@ url_regex = ftp://ftp.zoo.toronto.edu/pub/regex.shar
 
 url_linpack = http://www.math.iastate.edu/burkardt/f_src/linpack_bench/linpack_bench.f
 
+version_gmp = 4.1.4
+url_gmp = ftp://ftp.gnu.org/gnu/gmp/gmp-$(version_gmp).tar.gz
+configure_gmp = --host=mips-unknown-elf
+
 darcs_gcclass = http://darcs.brianweb.net/gcclass
 darcs_classgen = http://darcs.brianweb.net/classgen
 
@@ -85,7 +89,7 @@ update_darcs_%: tasks/extract_darcs_%
        else \
                cd "build/$*" && wget -np -nH --cut-dirs=1 -rl 16 -N -X _darcs $(darcs_$*); \
        fi
-       rm "tasks/build_darcs_$*" # to force a rebuild
+       rm -f "tasks/build_darcs_$*" # to force a rebuild
 
 tasks/build_darcs_%: tasks/extract_darcs_%
        cd "build/$*" && $(MAKE)
@@ -139,7 +143,7 @@ tasks/patch_%: tasks/extract_%
        if [ -e $@ ]; then echo "Error: $@ exists. something isn't right"; false; else true; fi
        cd build/$*-$(version_$*) &&  \
        for p in $(patches_$*) end; do \
-               [ "$$p" = "end" ] || $(PATCH) -p0 < ../../patches/$$p || exit 1; \
+               [ "$$p" = "end" ] || $(PATCH) -p0 -l < ../../patches/$$p || exit 1; \
        done
        touch $@
 
@@ -208,7 +212,14 @@ tasks/build_regex: tasks/download_regex tasks/build_newlib
                cp libregex.a $(usr)/mips-unknown-elf/lib 
        touch $@
 
-
+tasks/build_gmp: tasks/patch_gmp tasks/build_libc
+       cd build/gmp && \
+               CFLAGS="$(MIPS_CFLAGS)" LDFLAGS="$(MIPS_LDFLAGS)" \
+               ./configure --prefix=$(usr) $(configure_gmp) && \
+               make && \
+               make install exec_prefix=$(usr)/mips-unknown-elf includedir=$(usr)/mips-unknown-elf/include
+       touch $@
+       
 #
 # Tests
 # These are simply here for convenience. They aren't required 
@@ -223,11 +234,12 @@ url_libmspack = http://www.kyz.uklinux.net/downloads/libmspack-$(version_libmspa
 patches_libmspack = libmspack.patch
 
 version_freetype = 2.1.4
-url_freetype = http://umn.dl.sourceforge.net/sourceforge/freetype/freetype-$(version_freetype).tar.gz
+url_freetype = http://easynews.dl.sourceforge.net/sourceforge/freetype/freetype-$(version_freetype).tar.gz
 patches_freetype = freetype.patch ft-nostdio.patch
 
 version_boehmgc = 6.3alpha2
-url_boehmgc = http://www.hpl.hp.com/personal/Hans_Boehm/gc/gc_source/gc$(version_boehmgc).tar.gz
+#url_boehmgc = http://www.hpl.hp.com/personal/Hans_Boehm/gc/gc_source/gc$(version_boehmgc).tar.gz
+url_boehmgc = http://www.brianweb.net/misc/gc$(version_boehmgc).tar.gz
 patches_boehmgc = boehm-gc.patch
 
 version_busybox = 1.00-pre9
@@ -237,6 +249,10 @@ patches_busybox = busybox.patch
 version_texinputs = 1.0
 url_texinputs = http://www.megacz.com/tmp/texinputs-$(version_texinputs).tgz
 
+version_samba = 3.0.4
+url_samba = http://us4.samba.org/samba/ftp/samba-$(version_samba).tar.gz
+patches_samba = samba.patch
+
 tasks/extract_libjpeg: tasks/download_libjpeg
        mkdir -p build
        cd build && \
@@ -340,3 +356,12 @@ tasks/build_tex: tasks/build_tex_tangle tasks/build_gpc tasks/download_texinputs
                        && \
                mips-unknown-elf-gpc $(MIPS_PCFLAGS) tex.p $(MIPS_LDFLAGS) -o tex.mips
        touch $@
+
+tasks/build_samba: tasks/patch_samba
+       cd build/samba-$(version_samba)/source && \
+               test -e config.status || ./configure --host=mips-unknown-elf && \
+               fgrep -q '#define HAVE_GETTIMEOFDAY_TZ' include/config.h || \
+                       echo '#define HAVE_GETTIMEOFDAY_TZ 1' >> include/config.h && \
+               make LIBS="-lglob" CFLAGS="$(MIPS_CFLAGS)" LDFLAGS="$(MIPS_LDFLAGS)" \
+                    CONFIGFILE="smb.conf" proto_exists bin/ntlm_auth
+       touch $@