diff options
author | Maximiliano Curia <maxy@debian.org> | 2016-05-07 09:15:28 +0200 |
---|---|---|
committer | Maximiliano Curia <maxy@debian.org> | 2016-05-07 09:15:28 +0200 |
commit | 7d11f75a3ab3ccd903c6d9fac18b52ad9716fba1 (patch) | |
tree | d65fbfed03193e424e8eac03b01eb8dbec1f8e8f | |
parent | 943f4e0fd1f71829ec0aa9caf1a19c7a739dbf6b (diff) | |
download | pkg-kde-tools-7d11f75a3ab3ccd903c6d9fac18b52ad9716fba1.tar.gz |
pkgkde-symbolshelper: Add time_t type substitution.
-rw-r--r-- | debian/changelog | 3 | ||||
-rw-r--r-- | perllib/Debian/PkgKde/SymbolsHelper/Substs.pm | 1 | ||||
-rw-r--r-- | perllib/Debian/PkgKde/SymbolsHelper/Substs/TypeSubst.pm | 20 |
3 files changed, 24 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog index 257f033..3de1973 100644 --- a/debian/changelog +++ b/debian/changelog @@ -8,6 +8,9 @@ pkg-kde-tools (0.15.21) UNRELEASED; urgency=medium specified in the symbols file. * Use canonical URL in Vcs-Browser field. + [ Maximiliano Curia ] + * pkgkde-symbolshelper: Add time_t type substitution. + -- Debian Qt/KDE Maintainers <debian-qt-kde@lists.debian.org> Wed, 06 Jan 2016 20:52:49 +0300 pkg-kde-tools (0.15.20) unstable; urgency=medium diff --git a/perllib/Debian/PkgKde/SymbolsHelper/Substs.pm b/perllib/Debian/PkgKde/SymbolsHelper/Substs.pm index 4ebe58c..805a87a 100644 --- a/perllib/Debian/PkgKde/SymbolsHelper/Substs.pm +++ b/perllib/Debian/PkgKde/SymbolsHelper/Substs.pm @@ -36,6 +36,7 @@ our @TYPE_SUBSTS = ( "${NS}::TypeSubst::quintptr"->new(), "${NS}::TypeSubst::intptr_t"->new(), "${NS}::TypeSubst::qreal"->new(), + "${NS}::TypeSubst::time_t"->new(), ); our @CPP_TYPE_SUBSTS; diff --git a/perllib/Debian/PkgKde/SymbolsHelper/Substs/TypeSubst.pm b/perllib/Debian/PkgKde/SymbolsHelper/Substs/TypeSubst.pm index b9da8a9..1dca05c 100644 --- a/perllib/Debian/PkgKde/SymbolsHelper/Substs/TypeSubst.pm +++ b/perllib/Debian/PkgKde/SymbolsHelper/Substs/TypeSubst.pm @@ -297,6 +297,26 @@ sub _expand { return ($arch =~ /^(arm|armeb|armel|armhf|sh4)$/) ? 'f' : 'd'; } +package Debian::PkgKde::SymbolsHelper::Substs::TypeSubst::time_t; + +use strict; +use warnings; +use base 'Debian::PkgKde::SymbolsHelper::Substs::TypeSubst'; + +sub new { + my $class = shift; + my $self = $class->SUPER::new(@_); + $self->{substvar} = "{time_t}"; + $self->{types} = [ qw(x l) ]; # long long / long + return $self; +} + +sub _expand { + my ($self, $arch) = @_; + # see bits/types.h and bits/typesizes.h, long everywhere, except in x32 + return ($arch =~ /^(x32)$/) ? 'x' : 'l'; +} + package Debian::PkgKde::SymbolsHelper::Substs::TypeSubst; use strict; |