blob: 0150e90a6097efb8e3eeffc470528fcf7edf3045 [file] [log] [blame]
Uwe Hermann2dc5f422006-11-20 20:32:35 +00001-------------------------------------------------------------------------------
Peter Stuge44dd3042009-04-20 12:34:30 +00002flashrom README
Uwe Hermann2dc5f422006-11-20 20:32:35 +00003-------------------------------------------------------------------------------
Ronald G. Minnich1e5003f2002-04-10 18:02:07 +00004
Carl-Daniel Hailfinger1ebf8452009-08-18 23:50:14 +00005flashrom is a utility for detecting, reading, writing, verifying and erasing
6flash chips. It is often used to flash BIOS/EFI/coreboot/firmware images
7in-system using a supported mainboard, but it also supports flashing of network
Uwe Hermannc7e8a0c2009-05-19 14:14:21 +00008cards (NICs), SATA controller cards, and other external devices which can
9program flash chips.
Uwe Hermanne74b9f82009-04-10 14:41:29 +000010
Carl-Daniel Hailfinger1ebf8452009-08-18 23:50:14 +000011It supports a wide range of DIP32, PLCC32, DIP8, SO8/SOIC8, TSOP32, and TSOP40
12chips, which use various protocols such as LPC, FWH, parallel flash, or SPI.
Uwe Hermann42eb17f2008-01-18 17:48:51 +000013
Stefan Reinauer009c51b2010-01-03 23:50:28 +000014Please see the flashrom(8) manpage.
15
Uwe Hermann2dc5f422006-11-20 20:32:35 +000016
Carl-Daniel Hailfingera23041c2009-06-12 14:49:10 +000017Packaging
18---------
19
20To package flashrom and remove dependencies on subversion, either use
21make export
22or
23make tarball
24
25make export will export all flashrom files from the subversion repository at
26revision BASE into a directory named $EXPORTDIR/flashrom-$VERSION-r$SVNREVISION
27and will additionally modify the Makefile in that directory to contain the svn
28revision of the exported tree.
29
30make tarball will simply tar up the result of make export and gzip compress it.
31
32The snapshot tarballs are the result of make tarball and require no further
33processing.
34
35
Uwe Hermannd1129ac2009-05-28 15:07:42 +000036Build Instructions
Stefan Reinauer06b2c4d2005-12-01 10:51:08 +000037------------------
38
Uwe Hermann87c07932009-05-05 16:15:46 +000039To build flashrom you need to install the following packages or ports:
Stefan Reinauer06b2c4d2005-12-01 10:51:08 +000040
Idwer Vollering5e410de2009-05-03 23:33:05 +000041Linux et al:
Uwe Hermann87c07932009-05-05 16:15:46 +000042
Carl-Daniel Hailfingera472b8b2009-10-03 17:08:02 +000043 * pciutils / libpci
Uwe Hermann87c07932009-05-05 16:15:46 +000044 * pciutils-devel / pciutils-dev / libpci-dev
Carl-Daniel Hailfinger10572fa2009-08-17 16:30:53 +000045 * zlib-devel / zlib1g-dev (only needed if libpci is static)
Stefan Reinauer06b2c4d2005-12-01 10:51:08 +000046
Idwer Vollering5e410de2009-05-03 23:33:05 +000047On FreeBSD, you need the following ports:
Idwer Vollering5e410de2009-05-03 23:33:05 +000048
Uwe Hermann87c07932009-05-05 16:15:46 +000049 * devel/gmake
50 * devel/libpci
Idwer Vollering5e410de2009-05-03 23:33:05 +000051
Uwe Hermann87c07932009-05-05 16:15:46 +000052To compile on Linux, use:
Carl-Daniel Hailfinger9abf5292009-05-01 16:34:32 +000053
Uwe Hermann87c07932009-05-05 16:15:46 +000054 make
55
56To compile on FreeBSD, use:
57
58 gmake
59
Carl-Daniel Hailfinger10572fa2009-08-17 16:30:53 +000060To compile on Nexenta, use:
61
62 make
63
Uwe Hermann87c07932009-05-05 16:15:46 +000064To compile on Solaris, use:
65
Carl-Daniel Hailfinger10572fa2009-08-17 16:30:53 +000066 gmake LDFLAGS="-L$pathtolibpci" CC="gcc -I$pathtopciheaders" CFLAGS=-O2
Uwe Hermann87c07932009-05-05 16:15:46 +000067
Jonathan A. Kollasch3646c8f2010-01-08 21:18:08 +000068To compile on NetBSD or DragonFly BSD, use:
Uwe Hermann87c07932009-05-05 16:15:46 +000069
70 ln -s /usr/pkg/include/pciutils pci
Jonathan A. Kollaschd8dfc442010-02-16 00:49:50 +000071 gmake CPPFLAGS=-I. LDFLAGS="-L/usr/pkg/lib -Wl,-rpath-link,/usr/pkg/lib"
Carl-Daniel Hailfinger9abf5292009-05-01 16:34:32 +000072
73To compile and run on Darwin/Mac OS X:
Uwe Hermann87c07932009-05-05 16:15:46 +000074
75 Install DirectIO from coresystems GmbH.
76 DirectIO is available at http://www.coresystems.de/en/directio.
Carl-Daniel Hailfinger9abf5292009-05-01 16:34:32 +000077
Stefan Reinauer06b2c4d2005-12-01 10:51:08 +000078
Uwe Hermannd1129ac2009-05-28 15:07:42 +000079Installation
80------------
81
82In order to install flashrom and the manpage into /usr/local, type:
83
Carl-Daniel Hailfingera472b8b2009-10-03 17:08:02 +000084 make install
Uwe Hermannd1129ac2009-05-28 15:07:42 +000085
86For installation in a different directory use DESTDIR, e.g. like this:
87
Carl-Daniel Hailfingera472b8b2009-10-03 17:08:02 +000088 make DESTDIR=/usr install
89
90If you have insufficient permissions for the destination directory, use sudo
91by adding sudo in front of the commands above.
Uwe Hermannd1129ac2009-05-28 15:07:42 +000092
93
Joerg Mayer7221d5f2009-08-24 13:24:52 +000094Contact
Uwe Hermanne94dbf22009-05-22 13:18:38 +000095-------
96
97The official flashrom website is:
98
Stefan Reinauer22ea8cd2009-07-30 13:32:26 +000099 http://www.flashrom.org/
Uwe Hermannb6d28322006-12-04 08:15:47 +0000100
Joerg Mayer7221d5f2009-08-24 13:24:52 +0000101The IRC channel is
102
103 #flashrom at irc.freenode.net
104
105The Mailing list addess is
106
107 flashrom@flashrom.org