mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-12-23 17:55:37 +00:00
Remove some temporary scripts
This commit is contained in:
parent
0edba1a8ee
commit
45df597028
|
@ -1,37 +0,0 @@
|
|||
#!/bin/sh
|
||||
|
||||
# test result with:
|
||||
# make all check
|
||||
|
||||
set -eu
|
||||
|
||||
tmp/analyze-names.sh
|
||||
tmp/makelist.pl public-names extra-names > old2new
|
||||
|
||||
scripts/rename.pl -f old2new \
|
||||
library/*.c tests/suites/* configs/* scripts/data_files/*.fmt
|
||||
scripts/rename.pl -f old2new -s \
|
||||
library/error.c library/version_features.c \
|
||||
library/memory_buffer_alloc.c include/mbedtls/*.h \
|
||||
library/ecp.c library/ssl_???.c tests/ssl-opt.sh \
|
||||
programs/*.c programs/*/*.c scripts/* tests/scripts/*
|
||||
|
||||
for i in scripts/generate_errors.pl scripts/memory.sh tests/compat.sh \
|
||||
tests/suites/test_suite_version.data configs/README.txt
|
||||
do
|
||||
sed -e 's/POLARSSL/MBEDTLS/g' -e 's/polarssl/mbedtls/g' < $i > $i.tmp
|
||||
mv $i.tmp $i
|
||||
done
|
||||
chmod +x scripts/generate_errors.pl scripts/memory.sh tests/compat.sh
|
||||
|
||||
sed -e 's/server5-mbedtls_sha1/server5-sha1/' -i.tmp tests/ssl-opt.sh
|
||||
rm -f tests/ssl-opt.sh.tmp
|
||||
|
||||
echo; echo 'Done. Remaining polarssl occurences:'
|
||||
rm -f enum-consts exported-symbols extra-names identifiers macros old2new \
|
||||
prefix-enum-consts prefix-identifiers prefix-macros public-names \
|
||||
tags cscope*
|
||||
grep -R --exclude-dir=.git --exclude-dir=mpg --exclude-dir=tmp \
|
||||
--exclude=.travis.yml --exclude=ChangeLog \
|
||||
-i polarssl . \
|
||||
| egrep -v 'OU?=PolarSSL|"PolarSSL|polarssl\.example' || true
|
|
@ -1,65 +0,0 @@
|
|||
#!/usr/bin/perl
|
||||
|
||||
use warnings;
|
||||
use strict;
|
||||
|
||||
use utf8;
|
||||
use open qw(:std utf8);
|
||||
|
||||
# build substitution table from a list of names on stdin or input files
|
||||
|
||||
my %special_cases = (
|
||||
'supported_ciphers' => 'mbedtls_cipher_supported',
|
||||
'f' => 'mbedtls_entropy_f',
|
||||
'source' => 'mbedtls_entropy_source',
|
||||
'COLLECT' => 'MBEDTLS_HAVEGE_COLLECT',
|
||||
'LN' => 'MBEDTLS_MPI_LN',
|
||||
'key' => 'mbedtls_ssl_key',
|
||||
'safer' => 'mbedtls_ssl_safer',
|
||||
'alarmed' => 'mbedtls_timing_alarmed',
|
||||
'get' => 'mbedtls_timing_get',
|
||||
'hardclock' => 'mbedtls_timing_hardclock',
|
||||
'hr' => 'mbedtls_timing_hr',
|
||||
'm' => 'mbedtls_timing_m',
|
||||
'set' => 'mbedtls_timing_set',
|
||||
'BADCERT' => 'MBEDTLS_X509_BADCERT',
|
||||
'BADCRL' => 'MBEDTLS_X509_BADCRL',
|
||||
'EXT' => 'MBEDTLS_X509_EXT',
|
||||
'KU' => 'MBEDTLS_X509_KU',
|
||||
'NS' => 'MBEDTLS_X509_NS',
|
||||
't' => 'mbedtls_mpi',
|
||||
);
|
||||
|
||||
my %subst;
|
||||
while( my $name = <> ) {
|
||||
my $new;
|
||||
|
||||
chomp $name;
|
||||
|
||||
while( my ($prefix, $newpref) = each %special_cases ) {
|
||||
if( $name =~ /^$prefix($|_)/ ) {
|
||||
($new = $name) =~ s/^$prefix/$newpref/;
|
||||
last;
|
||||
}
|
||||
}
|
||||
|
||||
unless( $new ) {
|
||||
if( $name =~ /^POLARSSL_/ ) {
|
||||
($new = $name) =~ s/POLARSSL/MBEDTLS/;
|
||||
} elsif( $name =~ /^polarssl_/ ) {
|
||||
($new = $name) =~ s/polarssl/mbedtls/;
|
||||
} elsif( $name =~ /^_[a-z]/ ) {
|
||||
$new = "mbedtls$name";
|
||||
} elsif( $name =~ /^[A-Z]/ ) {
|
||||
$new = "MBEDTLS_$name";
|
||||
} elsif( $name =~ /^[a-z]/ ) {
|
||||
$new = "mbedtls_$name";
|
||||
} else {
|
||||
die "I don't know how to rename '$name'";
|
||||
}
|
||||
}
|
||||
|
||||
$subst{$name} = $new;
|
||||
}
|
||||
|
||||
printf "%s %s\n", $_, $subst{$_} for sort keys %subst;
|
Loading…
Reference in a new issue