unify license text

This commit is contained in:
iceman1001 2022-03-20 09:31:53 +01:00
commit bc46696dc4
27 changed files with 399 additions and 58 deletions

View file

@ -336,14 +336,15 @@ static int FpgaGatherVersion(FILE *infile, char *infile_name, char *dst, int len
if (!memcmp("fpga_lf", basename(infile_name), 7))
strncat(dst, "LF", len - strlen(dst) - 1);
else if (!memcmp("fpga_hf", basename(infile_name), 7))
else if (!memcmp("fpga_hf_15", basename(infile_name), 10))
strncat(dst, "HF 15", len - strlen(dst) - 1);
else if (!memcmp("fpga_hf.", basename(infile_name), 8))
strncat(dst, "HF", len - strlen(dst) - 1);
else if (!memcmp("fpga_felica", basename(infile_name), 7))
strncat(dst, "HF FeliCa", len - strlen(dst) - 1);
strncat(dst, " image built", len - strlen(dst) - 1);
strncat(dst, " image ", len - strlen(dst) - 1);
if (bitparse_find_section(infile, 'b', &fpga_info_len)) {
strncat(dst, " for ", len - strlen(dst) - 1);
for (uint32_t i = 0; i < fpga_info_len; i++) {
char c = (char)fgetc(infile);
if (i < sizeof(tempstr)) {
@ -353,8 +354,8 @@ static int FpgaGatherVersion(FILE *infile, char *infile_name, char *dst, int len
strncat(dst, tempstr, len - strlen(dst) - 1);
}
strncat(dst, " ", len - strlen(dst) - 1);
if (bitparse_find_section(infile, 'c', &fpga_info_len)) {
strncat(dst, " on ", len - strlen(dst) - 1);
for (uint32_t i = 0; i < fpga_info_len; i++) {
char c = (char)fgetc(infile);
if (i < sizeof(tempstr)) {
@ -367,7 +368,7 @@ static int FpgaGatherVersion(FILE *infile, char *infile_name, char *dst, int len
}
if (bitparse_find_section(infile, 'd', &fpga_info_len)) {
strncat(dst, " at ", len - strlen(dst) - 1);
strncat(dst, " ", len - strlen(dst) - 1);
for (uint32_t i = 0; i < fpga_info_len; i++) {
char c = (char)fgetc(infile);
if (i < sizeof(tempstr)) {
@ -382,9 +383,9 @@ static int FpgaGatherVersion(FILE *infile, char *infile_name, char *dst, int len
static void print_version_info_preamble(FILE *outfile, int num_infiles) {
fprintf(outfile, "//-----------------------------------------------------------------------------\n");
fprintf(outfile, "// piwi, 2018\n");
fprintf(outfile, "// Copyright (C) Proxmark3 contributors. See AUTHORS.md for details.\n");
fprintf(outfile, "//\n");
fprintf(outfile, "// This code is licensed to you under the terms of the GNU GPL, version 2 or,\n");
fprintf(outfile, "// This code is licensed to you under the terms of the GNU GPL, version 3 or,\n");
fprintf(outfile, "// at your option, any later version. See the LICENSE.txt file for the text of\n");
fprintf(outfile, "// the license.\n");
fprintf(outfile, "//-----------------------------------------------------------------------------\n");
@ -392,7 +393,6 @@ static void print_version_info_preamble(FILE *outfile, int num_infiles) {
fprintf(outfile, "//\n");
fprintf(outfile, "// This file is generated by fpga_compress. Don't edit!\n");
fprintf(outfile, "//-----------------------------------------------------------------------------\n");
fprintf(outfile, "// slurdge, 2020\n");
fprintf(outfile, "\n\n");
fprintf(outfile, "const int g_fpga_bitstream_num = %d;\n", num_infiles);
fprintf(outfile, "const char *const g_fpga_version_information[%d] = {\n", num_infiles);