def check_installed_debian(pkgname):
    """
    References:
        http://www.cyberciti.biz/faq/find-out-if-package-is-installed-in-linux/
    """
    import utool as ut
    #pkgname = 'espeak'
    #pkgname = 'sudo'
    #ut.cmd('hash ' + pkgname + ' 2>/dev/null')
    tup = ut.cmd('hash ' + pkgname + ' 2>/dev/null', quiet=True, pad_stdout=False)
    out, err, ret = tup
    is_installed = (ret == 0)
    return is_installed