On Tue, 20 Mar 2007 23:53:37 +0100 Tim Dijkstra <[EMAIL PROTECTED]> wrote:
> On Tue, 20 Mar 2007 22:43:37 +0100 > "Rafael J. Wysocki" <[EMAIL PROTECTED]> wrote: > > > Hm, well. I think that if we don't ship something, we should not have the > > option to compile it in our Makefile. > > > > Instead, we should update the documentation to tell the users that they > > should obtain the thing separately and what to do to get everything right. > > Well than we agree;) So I remove all of it from the Makefile and updated the docs. OK? Index: HOWTO =================================================================== RCS file: /cvsroot/suspend/suspend/HOWTO,v retrieving revision 1.18 diff -u -r1.18 HOWTO --- HOWTO 2 Feb 2007 12:10:26 -0000 1.18 +++ HOWTO 22 Mar 2007 12:39:31 -0000 @@ -15,9 +15,10 @@ crw-r--r-- 1 root root 10, 231 Jan 13 21:21 /dev/snapshot -(e) [optionally] Marc Lehmann's libLZF library (for image compression) -(f) [optionally] libgcrypt (for image encryption) -(g) [optionally] libsplashy (for user space splash) +(e) libx86, a hardware-independent library for executing real-mode x86 code +(f) [optionally] Marc Lehmann's libLZF library (for image compression) +(g) [optionally] libgcrypt (for image encryption) +(h) [optionally] libsplashy (for user space splash) 2) Basic steps @@ -41,7 +42,23 @@ The kernel installation procedure will depend on what Linux distribution you use and should be documented elsewhere. -(b) [optionally] Install the Marc Lehmann's libLZF library +(b) Install libx86 developement packages + +If libx86 is not installed on your system (Debian: libx86-dev) you can download +the tarball from http://www.codon.org.uk/~mjg59/libx86/downloads/. Unpack it, +change into the resulting directory. Then run + +$ make + +or if you're building for an x86_64 + +$ make BACKEND=x86emu + +Next, become root and run + +# make install DESTDIR=/usr/local + +(c) [optionally] Install the Marc Lehmann's libLZF library If you want to use the image compression functionality and libLZF it's not installed on your system, download the tarball from @@ -58,7 +75,7 @@ [This will put the lzf.h file into /usr/local/include, the library into /usr/local/lib, and the lzf binary into /usr/local/bin.] -(c) [optionally] Install libgrypt +(d) [optionally] Install libgrypt If you want to use the image encryption functionality of the suspend tools, you'll need libgcrypt to build them. If you have installed Index: Makefile =================================================================== RCS file: /cvsroot/suspend/suspend/Makefile,v retrieving revision 1.52 diff -u -r1.52 Makefile --- Makefile 16 Mar 2007 15:03:08 -0000 1.52 +++ Makefile 22 Mar 2007 12:39:31 -0000 @@ -3,7 +3,6 @@ #CONFIG_SPLASHY=yes #CONFIG_UDEV=yes #CONFIG_RESUME_DYN=yes -#CONFIG_EMBEDDED_LIBX86=yes SUSPEND_DIR=/usr/local/sbin RESUME_DIR=/usr/local/lib/suspend @@ -20,17 +19,13 @@ CC_FLAGS=-I/usr/local/include -DS2RAM $(CFLAGS) LD_FLAGS=-L/usr/local/lib -ifdef CONFIG_EMBEDDED_LIBX86 -CC_FLAGS += -Ilibx86/ -endif - BINARIES=s2disk s2both s2ram swap-offset resume BINARIES_MIN=s2disk swap-offset -S2RAM_OBJ=vt.o vbetool/x86-common.o vbetool/vbetool.o radeontool.o dmidecode.o +S2RAM_OBJ=vt.o vbetool/vbetool.o radeontool.o dmidecode.o SWSUSP_OBJ=vt.o md5.o encrypt.o config.o loglevel.o splash.o bootsplash.o -S2RAM_LD_FLAGS = $(LD_FLAGS) -lpci -lz +S2RAM_LD_FLAGS = $(LD_FLAGS) -lpci -lz -lx86 SWSUSP_LD_FLAGS = $(LD_FLAGS) ifndef CONFIG_RESUME_DYN @@ -70,25 +65,17 @@ STATIC_CC_FLAGS=$(shell directfb-config --cflags)\ $(shell pkg-config --static --cflags glib-2.0) endif +ifdef CONFIG_RESUME_DYN +SWSUSP_LD_FLAGS += -lgcc_s endif - -### -ifdef CONFIG_EMBEDDED_LIBX86 -ifeq ($(ARCH), x86_64) -LIBX86_MAKE = BACKEND=x86emu endif -S2RAM_OBJ += libx86/libx86.a -else -S2RAM_LD_FLAGS += -lx86 -endif -all: $(BINARIES) -clean: - make -C libx86 clean || true - rm -f $(BINARIES) suspend-keygen suspend.keys *.o vbetool/*.o +all: $(BINARIES) +clean: + rm -f $(BINARIES) suspend-keygen suspend.keys *.o vbetool/*.o #### Rules for objects s2ram-both.o: s2ram.c s2ram.h whitelist.c @@ -101,21 +88,13 @@ $(CC) $(CC_FLAGS) -DHAVE_INTTYPES_H -DHAVE_STDINT_H -c $< -o $@ # Simple objects with header -config.o vt.o bootsplash.o splash.o splashy_funcs.o vbetool/x86-common.o vbetool/vbetool.o: %.o : %.c %.h +config.o vt.o bootsplash.o splash.o splashy_funcs.o vbetool/vbetool.o: %.o : %.c %.h $(CC) $(CC_FLAGS) -c $< -o $@ # Simple object without header dmidecode.o radeontool.o : %.o: %.c $(CC) $(CC_FLAGS) -c $< -o $@ -libx86/libx86.a: - ln -sf lrmi.h libx86/libx86.h - make -C libx86 $(LIBX86_MAKE) static - -libx86/lrmi.o libx86/thunk.o: %.o: %.c - $(CC) $(CC_FLAGS) -c $< -o $@ - - #### Rules for binaries s2disk: $(SWSUSP_OBJ) suspend.c $(CC) -g $(CC_FLAGS) $^ -o $@ $(SWSUSP_LD_FLAGS) @@ -169,3 +148,4 @@ install: $(patsubst %,install-%,$(BINARIES)) $(SNAPSHOT) install-conf +.PHONY: clean install install-minimal install-resume-on-initrd install-resume-new-initrd $(patsubst %,install-%,$(BINARIES)) Index: README =================================================================== RCS file: /cvsroot/suspend/suspend/README,v retrieving revision 1.9 diff -u -r1.9 README --- README 16 Mar 2007 15:03:08 -0000 1.9 +++ README 22 Mar 2007 12:39:32 -0000 @@ -42,12 +42,6 @@ http://www.codon.org.uk/~mjg59/vbetool/). With newer pciutils (2.2.4 and above) you also have to install the zlib development package (zlib-devel on SUSE, zlib1g-dev on Debian). -You can build against a system wide installed libx86 or against an locally -unpacked tarball inside the suspend source directory. To build against the -locally unpacked tarball, get it from http://www.codon.org.uk/~mjg59/libx86, -unpack it inside the suspend directory and create a link to that directory -with "ln -s libx86-0.99 libx86". Then edit the Makefile and uncomment the -CONFIG_EMBEDDED_LIBX86=yes line. For debugging, see http://www.opensuse.org/ACPI_Suspend_debugging and http://en.opensuse.org/S2ram . ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Suspend-devel mailing list Suspend-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/suspend-devel