Jerry Van Baren wrote: > The discussion has mostly been emotional to date. Here are some > statistics (not necessarily perfect, but pretty close)... > > Total number of files (after removing the .git files): > $ find . -type f | wc -l > 6055 > > Number of files that are identified as being copyrighted: > $ grep -l -i -r 'Copyright' * | wc -l > 5173 > > List of files with copyrights: > $ grep -l -i -r 'Copyright' * | sort > ~/ucopy.txt > > List of all files: > $ find . -type f | sed 's/.\///' | sort > ~/ufiles.txt > > List of files *WITHOUT* the string "copyright" in them: > $ comm -3 ~/ufiles.txt ~/ucopy.txt > ~/nocopyright.txt > > Of the above, 130 of the files have the GPL in the header but not the > string "copyright" - incomplete headers: > for file in `cat ~/nocopyright.txt` ; do grep -il 'General Public > License' $file ; done | wc -l > 130 > > ---------------------------------------------------------------------
Improving my fingerprinting (thanks, Scott): Total number of files that are GPLv2. Sometimes the FSF and GPL strings are split across lines. This assumes that one of the two strings is all on one line. Still simplistic, but less so. Another important disclaimer: a lot of the GPLv2-ONLY files come from the linux kernel (see the list below). If and when we move to the U-Boot v2 driver interface, where we will be able to use linux drivers more easily, the number of GPLv2-ONLY driver files will likely increase. $ grep -i -l -r 'Free Software Foundation' * | sort > ufsf.txt $ grep -i -l -r 'General Public License' * | sort > ugpl.txt $ cat ufsf.txt ugpl.txt | sort -u > ugplv2.txt $ wc -l ugplv2.txt 4798 ugplv2.txt $ cat ugplv2.txt | xargs grep 'either version 2' | awk '{print $1}' | sed 's/:#*//' > ugplv2-or-later.txt $ wc -l ugplv2-or-later.txt 4539 ugplv2-or-later.txt $ for file in `cat ugplv2.txt` ; do grep -il 'version 2' $file ; done | wc -l 4763 Looking for GPLv2 ONLY files (has some false positives): $ comm -23 ugplv2.txt ugplv2-or-later.txt > ugplv2-only.txt After reviewing the files, I come up with 233 GPLv2-only files: $ wc -l ugplv2-only.txt 233 ugplv2-only.txt $ cat ugplv2-only.txt board/amirix/ap1000/ap1000.c board/amirix/ap1000/ap1000.h board/amirix/ap1000/init.S board/atum8548/ddr.c board/freescale/common/pq-mds-pib.c board/freescale/common/pq-mds-pib.h board/freescale/mpc8323erdb/mpc8323erdb.c board/freescale/mpc8536ds/ddr.c board/freescale/mpc8540ads/ddr.c board/freescale/mpc8541cds/ddr.c board/freescale/mpc8544ds/ddr.c board/freescale/mpc8548cds/ddr.c board/freescale/mpc8555cds/ddr.c board/freescale/mpc8560ads/ddr.c board/freescale/mpc8568mds/ddr.c board/freescale/mpc8569mds/ddr.c board/freescale/mpc8572ds/ddr.c board/freescale/mpc8610hpcd/ddr.c board/freescale/mpc8641hpcn/ddr.c board/freescale/p2020ds/ddr.c board/linkstation/hwctl.c board/micronas/vct/smc_eeprom.c board/ml2/flash.c board/ml2/init.S board/ml2/ml2.c board/mpc8540eval/ddr.c board/mvblue/mvblue.c board/netstar/crcek.S board/netstar/eeprom.c board/netstar/eeprom_start.S board/pm854/ddr.c board/pm856/ddr.c board/sbc8548/ddr.c board/sbc8560/ddr.c board/sbc8641d/ddr.c board/socrates/ddr.c board/stxgp3/ddr.c board/stxssa/ddr.c board/voiceblue/eeprom.c board/voiceblue/eeprom_start.S board/voiceblue/Makefile board/voiceblue/setup.S board/voiceblue/voiceblue.c board/xes/xpedite5200/ddr.c common/cmd_onenand.c common/cmd_ubi.c common/ddr_spd.c cpu/arm926ejs/omap/cpuinfo.c cpu/mpc85xx/ddr-gen1.c cpu/mpc85xx/ddr-gen2.c cpu/mpc85xx/ddr-gen3.c cpu/mpc86xx/ddr-8641.c cpu/mpc86xx/fdt.c cpu/mpc8xxx/ddr/common_timing_params.h cpu/mpc8xxx/ddr/ctrl_regs.c cpu/mpc8xxx/ddr/ddr1_dimm_params.c cpu/mpc8xxx/ddr/ddr2_dimm_params.c cpu/mpc8xxx/ddr/ddr3_dimm_params.c cpu/mpc8xxx/ddr/ddr.h cpu/mpc8xxx/ddr/lc_common_dimm_params.c cpu/mpc8xxx/ddr/main.c cpu/mpc8xxx/ddr/Makefile cpu/mpc8xxx/ddr/options.c cpu/mpc8xxx/ddr/util.c drivers/bios_emulator/atibios.c drivers/bios_emulator/besys.c drivers/gpio/pca953x.c drivers/i2c/fsl_i2c.c drivers/misc/ds4510.c drivers/mmc/omap3_mmc.c drivers/mmc/pxa_mmc.h drivers/mtd/mtdcore.c drivers/mtd/nand/nand_base.c drivers/mtd/nand/nand_bbt.c drivers/mtd/nand/nand.c drivers/mtd/nand/nand_ids.c drivers/mtd/nand/nand_util.c drivers/mtd/onenand/onenand_base.c drivers/mtd/onenand/onenand_bbt.c drivers/mtd/onenand/onenand_uboot.c drivers/mtd/ubi/crc32.c drivers/net/5701rls.c drivers/net/5701rls.h drivers/net/ax88180.c drivers/net/ax88180.h drivers/net/bcm570x_autoneg.c drivers/net/bcm570x_autoneg.h drivers/net/bcm570x_bits.h drivers/net/bcm570x_debug.h drivers/net/bcm570x_lm.h drivers/net/bcm570x_mm.h drivers/net/bcm570x_queue.h drivers/net/dnet.c drivers/net/dnet.h drivers/net/natsemi.c drivers/net/nicext.h drivers/net/ns8382x.c drivers/net/tigon3.c drivers/net/tigon3.h drivers/net/vsc7385.c drivers/pci/fsl_pci_init.c drivers/rtc/rs5c372.c drivers/serial/arm_dcc.c drivers/usb/host/ehci-core.h drivers/usb/host/ehci.h drivers/usb/host/ehci-hcd.c drivers/usb/host/ehci-pci.c drivers/usb/host/r8a66597.h drivers/usb/host/r8a66597-hcd.c drivers/usb/musb/musb_core.h examples/82559_eeprom.c examples/eepro100_eeprom.c fs/cramfs/cramfs.c fs/cramfs/uncompress.c fs/jffs2/compr_rtime.c fs/jffs2/compr_rubin.c fs/jffs2/compr_zlib.c fs/jffs2/jffs2_1pass.c fs/ubifs/budget.c fs/ubifs/crc16.c fs/ubifs/crc16.h fs/ubifs/debug.c fs/ubifs/debug.h fs/ubifs/io.c fs/ubifs/key.h fs/ubifs/log.c fs/ubifs/lprops.c fs/ubifs/lpt.c fs/ubifs/lpt_commit.c fs/ubifs/master.c fs/ubifs/misc.h fs/ubifs/orphan.c fs/ubifs/recovery.c fs/ubifs/replay.c fs/ubifs/sb.c fs/ubifs/scan.c fs/ubifs/super.c fs/ubifs/tnc.c fs/ubifs/tnc_misc.c fs/ubifs/ubifs.c fs/ubifs/ubifs.h fs/ubifs/ubifs-media.h fs/yaffs2/devextras.h fs/yaffs2/Makefile fs/yaffs2/yaffscfg.c fs/yaffs2/yaffscfg.h fs/yaffs2/yaffs_checkptrw.c fs/yaffs2/yaffs_checkptrw.h fs/yaffs2/yaffs_ecc.c fs/yaffs2/yaffs_ecc.h fs/yaffs2/yaffs_flashif.h fs/yaffs2/yaffsfs.c fs/yaffs2/yaffsfs.h fs/yaffs2/yaffs_guts.c fs/yaffs2/yaffs_guts.h fs/yaffs2/yaffsinterface.h fs/yaffs2/yaffs_malloc.h fs/yaffs2/yaffs_mtdif2.c fs/yaffs2/yaffs_mtdif2.h fs/yaffs2/yaffs_mtdif.c fs/yaffs2/yaffs_mtdif.h fs/yaffs2/yaffs_nand.c fs/yaffs2/yaffs_nandemul2k.h fs/yaffs2/yaffs_nand.h fs/yaffs2/yaffs_packedtags1.c fs/yaffs2/yaffs_packedtags1.h fs/yaffs2/yaffs_packedtags2.c fs/yaffs2/yaffs_packedtags2.h fs/yaffs2/yaffs_qsort.h fs/yaffs2/yaffs_ramdisk.h fs/yaffs2/yaffs_tagscompat.c fs/yaffs2/yaffs_tagscompat.h fs/yaffs2/yaffs_tagsvalidity.c fs/yaffs2/yaffs_tagsvalidity.h fs/yaffs2/ydirectenv.h fs/yaffs2/yportenv.h include/addr_map.h include/asm-arm/arch-ixp/ixp425.h include/asm-arm/arch-omap3/mmc.h include/asm-arm/arch-omap3/mmc_host_def.h include/asm-arm/arch-pxa/hardware.h include/asm-arm/arch-pxa/pxa-regs.h include/asm-arm/atomic.h include/asm-arm/hardware.h include/asm-arm/io.h include/asm-arm/memory.h include/asm-arm/posix_types.h include/asm-arm/proc-armv/domain.h include/asm-arm/proc-armv/processor.h include/asm-arm/proc-armv/ptrace.h include/asm-arm/proc-armv/system.h include/asm-arm/processor.h include/asm-arm/setup.h include/asm-m68k/fsl_i2c.h include/asm-ppc/fsl_ddr_dimm_params.h include/asm-ppc/fsl_ddr_sdram.h include/asm-ppc/fsl_dma.h include/asm-ppc/fsl_i2c.h include/asm-ppc/mpc8xxx_spi.h include/asm-sh/io.h include/bcd.h include/configs/AP1000.h include/configs/ML2.h include/configs/MPC8323ERDB.h include/configs/MPC8610HPCD.h include/configs/voiceblue.h include/ddr_spd.h include/ds4510.h include/jffs2/jffs2.h include/linux/mc146818rtc.h include/linux/mtd/bbm.h include/linux/mtd/nand_ecc.h include/linux/mtd/nand.h include/linux/mtd/nand_ids.h include/linux/mtd/nand_legacy.h include/linux/mtd/ndfc.h include/linux/mtd/onenand.h include/linux/mtd/onenand_regs.h include/nand.h include/onenand_uboot.h include/pca953x.h include/pcmcia/cirrus.h include/pcmcia/i82365.h include/pcmcia/ss.h include/pcmcia/ti113x.h include/pcmcia/yenta.h include/sha1.h include/spi_flash.h include/ubi_uboot.h include/usb/omap1510_udc.h include/vsc7385.h lib_generic/addr_map.c lib_generic/sha1.c Files that have incomplete GPL license statements in their headers (typically missing which version of GPL applies). The Broadcom (bcm*.*) files mention GPL and reference the gentle reader to a file "LICENSE" for more information, but we don't have a "LICENSE" file, much less /their/ "LICENSE" file. board/linkstation/hwctl.c board/mvblue/mvblue.c drivers/net/5701rls.c drivers/net/5701rls.h drivers/net/bcm570x_autoneg.c drivers/net/bcm570x_autoneg.h drivers/net/bcm570x_bits.h drivers/net/bcm570x_debug.h drivers/net/bcm570x_lm.h drivers/net/bcm570x_mm.h drivers/net/bcm570x_queue.h drivers/net/natsemi.c drivers/net/nicext.h drivers/net/ns8382x.c drivers/net/tigon3.c drivers/net/tigon3.h examples/82559_eeprom.c examples/eepro100_eeprom.c lib_ppc/ppcstring.S LzmaDecode.[ch] is dual licensed LGPL and Common Public License (CPL), but the version of LGPL or CPL is not specified. Ahh, the directory has a file lib_generic/lzma/LGPL.txt that specifies LGPL 2.1 or later. lib_generic/lzma/LzmaDecode.c lib_generic/lzma/LzmaDecode.h Trivia: There are a few dual-licensed with MPL: include/pcmcia/cirrus.h include/pcmcia/i82365.h include/pcmcia/ss.h include/pcmcia/ti113x.h include/pcmcia/yenta.h ...and some dual-licensed with the Red Hat eCos Public License: board/cogent/lcd.c board/cogent/lcd.h fs/jffs2/compr_rtime.c fs/jffs2/compr_rubin.c fs/jffs2/compr_zlib.c fs/jffs2/jffs2_1pass.c include/jffs2/jffs2.h [snip] Best regards, gvb _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot