Merge branch 'next' of ssh://git.ipfire.org/pub/git/ipfire-2.x into next

This commit is contained in:
Stefan Schantl
2020-01-03 11:06:47 +01:00
58 changed files with 1426 additions and 838 deletions

View File

@@ -0,0 +1,3 @@
#!/bin/bash
exec /etc/init.d/unbound update-safe-search

View File

@@ -29,7 +29,7 @@ IPS_OUTPUT_CHAIN="IPS_OUTPUT"
NFQ_OPTS="--queue-bypass "
# Array containing the 4 possible network zones.
network_zones=( red green blue orange )
network_zones=( red green blue orange ovpn )
# Array to store the network zones weather the IPS is enabled for.
enabled_ips_zones=()
@@ -86,6 +86,22 @@ function generate_fw_rules {
if [ "$zone" == "red" ] && [ "$RED_TYPE" == "PPPOE" ]; then
# Set device name to ppp0.
network_device="ppp0"
elif [ "$zone" == "ovpn" ]; then
# Get all virtual net devices because the RW server and each
# N2N connection creates it's own tun device.
for virt_dev in /sys/devices/virtual/net/*; do
# Cut-off the directory.
dev="${virt_dev##*/}"
# Only process tun devices.
if [[ $dev =~ "tun" ]]; then
# Add the network device to the array of enabled zones.
enabled_ips_zones+=( "$dev" )
fi
done
# Process next zone.
continue
else
# Generate variable name which contains the device name.
zone_name="$zone_upper"

View File

@@ -549,7 +549,7 @@ resolve() {
}
# Sets up Safe Search for various search engines
write_safe_search_conf() {
update_safe_search() {
local google_tlds=(
google.ad
google.ae
@@ -746,51 +746,59 @@ write_safe_search_conf() {
google.ws
)
(
# Nothing to do if safe search is not enabled
if [ "${ENABLE_SAFE_SEARCH}" != "on" ]; then
exit 0
fi
# Cleanup previous settings
unbound-control local_zone_remove "bing.com" >/dev/null
unbound-control local_zone_remove "duckduckgo.com" >/dev/null
unbound-control local_zone_remove "yandex.com" >/dev/null
unbound-control local_zone_remove "yandex.ru" >/dev/null
unbound-control local_zone_remove "youtube.com" >/dev/null
# This all belongs into the server: section
echo "server:"
local domain
for domain in ${google_tlds[@]}; do
unbound-control local_zone_remove "${domain}"
done >/dev/null
# Bing
echo " local-zone: bing.com transparent"
for address in $(resolve "strict.bing.com"); do
echo " local-data: \"www.bing.com ${LOCAL_TTL} IN A ${address}\""
done
# Nothing to do if safe search is not enabled
if [ "${ENABLE_SAFE_SEARCH}" != "on" ]; then
return 0
fi
# DuckDuckGo
echo " local-zone: duckduckgo.com typetransparent"
for address in $(resolve "safe.duckduckgo.com"); do
echo " local-data: \"duckduckgo.com ${LOCAL_TTL} IN A ${address}\""
done
# Bing
unbound-control bing.com transparent >/dev/null
for address in $(resolve "strict.bing.com"); do
unbound-control local_data "www.bing.com ${LOCAL_TTL} IN A ${address}"
done >/dev/null
# Google
addresses="$(resolve "forcesafesearch.google.com")"
local domain
for domain in ${google_tlds[@]}; do
echo " local-zone: ${domain} transparent"
for address in ${addresses}; do
echo " local-data: \"www.${domain} ${LOCAL_TTL} IN A ${address}\""
done
done
# DuckDuckGo
unbound-control local_zone duckduckgo.com typetransparent >/dev/null
for address in $(resolve "safe.duckduckgo.com"); do
unbound-control local_data "duckduckgo.com ${LOCAL_TTL} IN A ${address}"
done >/dev/null
# Yandex
for domain in yandex.com yandex.ru; do
echo " local-zone: ${domain} typetransparent"
for address in $(resolve "familysearch.${domain}"); do
echo " local-data: \"${domain} ${LOCAL_TTL} IN A ${address}\""
done
done
# Google
local addresses="$(resolve "forcesafesearch.google.com")"
for domain in ${google_tlds[@]}; do
unbound-control local_zone "${domain}" transparent >/dev/null
for address in ${addresses}; do
unbound-control local_data: "www.${domain} ${LOCAL_TTL} IN A ${address}"
done >/dev/null
done
# YouTube
echo " local-zone: youtube.com transparent"
for address in $(resolve "restrictmoderate.youtube.com"); do
echo " local-data: \"www.youtube.com ${LOCAL_TTL} IN A ${address}\""
done
) > /etc/unbound/safe-search.conf
# Yandex
for domain in yandex.com yandex.ru; do
unbound-control local_zone "${domain}" typetransparent >/dev/null
for address in $(resolve "familysearch.${domain}"); do
unbound-control local_data "${domain} ${LOCAL_TTL} IN A ${address}"
done >/dev/null
done
# YouTube
unbound-control local_zone youtube.com transparent >/dev/null
for address in $(resolve "restrictmoderate.youtube.com"); do
unbound-control local_data "www.youtube.com ${LOCAL_TTL} IN A ${address}"
done >/dev/null
return 0
}
case "$1" in
@@ -806,7 +814,6 @@ case "$1" in
# Update configuration files
write_tuning_conf
write_forward_conf
write_safe_search_conf
boot_mesg "Starting Unbound DNS Proxy..."
loadproc /usr/sbin/unbound || exit $?
@@ -817,6 +824,11 @@ case "$1" in
# Update any known forwarding name servers
update_forwarders
# Install Safe Search rules when the system is already online
if [ -e "/var/ipfire/red/active" ]; then
update_safe_search
fi
# Update hosts
update_hosts
@@ -905,8 +917,12 @@ case "$1" in
resolve "${2}"
;;
update-safe-search)
update_safe_search
;;
*)
echo "Usage: $0 {start|stop|restart|status|update-forwarders|remove-forwarders|test-name-server|resolve}"
echo "Usage: $0 {start|stop|restart|status|update-forwarders|remove-forwarders|test-name-server|resolve|update-safe-search}"
exit 1
;;
esac

View File

@@ -144,7 +144,7 @@ sub fetchfile {
$file = $getfile;
}
$proto = "HTTP" unless $proto;
$proto = "HTTPS" unless $proto;
logger("DOWNLOAD INFO: Host: $host ($proto) - File: $file");
@@ -318,7 +318,7 @@ sub selectmirror {
if ($scount eq 0) {
logger("MIRROR INFO: Could not find any servers. Falling back to main server $Conf::mainserver");
return ("HTTP", $Conf::mainserver, "/$Conf::version");
return ("HTTPS", $Conf::mainserver, "/$Conf::version");
}
### Choose a random server and test if it is online

View File

@@ -0,0 +1,341 @@
From fd06998396d631f028fd8f8d7bcb2b442c578292 Mon Sep 17 00:00:00 2001
From: Johannes Berg <johannes@sipsolutions.net>
Date: Thu, 8 Jan 2015 09:02:42 +0100
Subject: use uapi rfkill.h
---
rfkill.h | 295 ++-------------------------------------------------------------
1 file changed, 6 insertions(+), 289 deletions(-)
diff --git a/rfkill.h b/rfkill.h
index d253b4e..058757f 100644
--- a/rfkill.h
+++ b/rfkill.h
@@ -1,6 +1,3 @@
-#ifndef __RFKILL_H
-#define __RFKILL_H
-
/*
* Copyright (C) 2006 - 2007 Ivo van Doorn
* Copyright (C) 2007 Dmitry Torokhov
@@ -18,6 +15,9 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
+#ifndef _UAPI__RFKILL_H
+#define _UAPI__RFKILL_H
+
#include <linux/types.h>
@@ -29,7 +29,7 @@
/**
* enum rfkill_type - type of rfkill switch.
*
- * @RFKILL_TYPE_ALL: toggles all switches (userspace only)
+ * @RFKILL_TYPE_ALL: toggles all switches (requests only - not a switch type)
* @RFKILL_TYPE_WLAN: switch is on a 802.11 wireless network device.
* @RFKILL_TYPE_BLUETOOTH: switch is on a bluetooth device.
* @RFKILL_TYPE_UWB: switch is on a ultra wideband device.
@@ -83,7 +83,7 @@ struct rfkill_event {
__u8 type;
__u8 op;
__u8 soft, hard;
-} __packed;
+} __attribute__((packed));
/*
* We are planning to be backward and forward compatible with changes
@@ -105,288 +105,5 @@ struct rfkill_event {
#define RFKILL_IOCTL_NOINPUT _IO(RFKILL_IOC_MAGIC, RFKILL_IOC_NOINPUT)
/* and that's all userspace gets */
-#ifdef __KERNEL__
-/* don't allow anyone to use these in the kernel */
-enum rfkill_user_states {
- RFKILL_USER_STATE_SOFT_BLOCKED = RFKILL_STATE_SOFT_BLOCKED,
- RFKILL_USER_STATE_UNBLOCKED = RFKILL_STATE_UNBLOCKED,
- RFKILL_USER_STATE_HARD_BLOCKED = RFKILL_STATE_HARD_BLOCKED,
-};
-#undef RFKILL_STATE_SOFT_BLOCKED
-#undef RFKILL_STATE_UNBLOCKED
-#undef RFKILL_STATE_HARD_BLOCKED
-
-#include <linux/kernel.h>
-#include <linux/list.h>
-#include <linux/mutex.h>
-#include <linux/device.h>
-#include <linux/leds.h>
-#include <linux/err.h>
-
-/* this is opaque */
-struct rfkill;
-
-/**
- * struct rfkill_ops - rfkill driver methods
- *
- * @poll: poll the rfkill block state(s) -- only assign this method
- * when you need polling. When called, simply call one of the
- * rfkill_set{,_hw,_sw}_state family of functions. If the hw
- * is getting unblocked you need to take into account the return
- * value of those functions to make sure the software block is
- * properly used.
- * @query: query the rfkill block state(s) and call exactly one of the
- * rfkill_set{,_hw,_sw}_state family of functions. Assign this
- * method if input events can cause hardware state changes to make
- * the rfkill core query your driver before setting a requested
- * block.
- * @set_block: turn the transmitter on (blocked == false) or off
- * (blocked == true) -- ignore and return 0 when hard blocked.
- * This callback must be assigned.
- */
-struct rfkill_ops {
- void (*poll)(struct rfkill *rfkill, void *data);
- void (*query)(struct rfkill *rfkill, void *data);
- int (*set_block)(void *data, bool blocked);
-};
-
-#if defined(CONFIG_RFKILL) || defined(CONFIG_RFKILL_MODULE)
-/**
- * rfkill_alloc - allocate rfkill structure
- * @name: name of the struct -- the string is not copied internally
- * @parent: device that has rf switch on it
- * @type: type of the switch (RFKILL_TYPE_*)
- * @ops: rfkill methods
- * @ops_data: data passed to each method
- *
- * This function should be called by the transmitter driver to allocate an
- * rfkill structure. Returns %NULL on failure.
- */
-struct rfkill * __must_check rfkill_alloc(const char *name,
- struct device *parent,
- const enum rfkill_type type,
- const struct rfkill_ops *ops,
- void *ops_data);
-
-/**
- * rfkill_register - Register a rfkill structure.
- * @rfkill: rfkill structure to be registered
- *
- * This function should be called by the transmitter driver to register
- * the rfkill structure. Before calling this function the driver needs
- * to be ready to service method calls from rfkill.
- *
- * If rfkill_init_sw_state() is not called before registration,
- * set_block() will be called to initialize the software blocked state
- * to a default value.
- *
- * If the hardware blocked state is not set before registration,
- * it is assumed to be unblocked.
- */
-int __must_check rfkill_register(struct rfkill *rfkill);
-
-/**
- * rfkill_pause_polling(struct rfkill *rfkill)
- *
- * Pause polling -- say transmitter is off for other reasons.
- * NOTE: not necessary for suspend/resume -- in that case the
- * core stops polling anyway
- */
-void rfkill_pause_polling(struct rfkill *rfkill);
-
-/**
- * rfkill_resume_polling(struct rfkill *rfkill)
- *
- * Pause polling -- say transmitter is off for other reasons.
- * NOTE: not necessary for suspend/resume -- in that case the
- * core stops polling anyway
- */
-void rfkill_resume_polling(struct rfkill *rfkill);
-
-
-/**
- * rfkill_unregister - Unregister a rfkill structure.
- * @rfkill: rfkill structure to be unregistered
- *
- * This function should be called by the network driver during device
- * teardown to destroy rfkill structure. Until it returns, the driver
- * needs to be able to service method calls.
- */
-void rfkill_unregister(struct rfkill *rfkill);
-
-/**
- * rfkill_destroy - free rfkill structure
- * @rfkill: rfkill structure to be destroyed
- *
- * Destroys the rfkill structure.
- */
-void rfkill_destroy(struct rfkill *rfkill);
-
-/**
- * rfkill_set_hw_state - Set the internal rfkill hardware block state
- * @rfkill: pointer to the rfkill class to modify.
- * @state: the current hardware block state to set
- *
- * rfkill drivers that get events when the hard-blocked state changes
- * use this function to notify the rfkill core (and through that also
- * userspace) of the current state. They should also use this after
- * resume if the state could have changed.
- *
- * You need not (but may) call this function if poll_state is assigned.
- *
- * This function can be called in any context, even from within rfkill
- * callbacks.
- *
- * The function returns the combined block state (true if transmitter
- * should be blocked) so that drivers need not keep track of the soft
- * block state -- which they might not be able to.
- */
-bool rfkill_set_hw_state(struct rfkill *rfkill, bool blocked);
-
-/**
- * rfkill_set_sw_state - Set the internal rfkill software block state
- * @rfkill: pointer to the rfkill class to modify.
- * @state: the current software block state to set
- *
- * rfkill drivers that get events when the soft-blocked state changes
- * (yes, some platforms directly act on input but allow changing again)
- * use this function to notify the rfkill core (and through that also
- * userspace) of the current state.
- *
- * Drivers should also call this function after resume if the state has
- * been changed by the user. This only makes sense for "persistent"
- * devices (see rfkill_init_sw_state()).
- *
- * This function can be called in any context, even from within rfkill
- * callbacks.
- *
- * The function returns the combined block state (true if transmitter
- * should be blocked).
- */
-bool rfkill_set_sw_state(struct rfkill *rfkill, bool blocked);
-
-/**
- * rfkill_init_sw_state - Initialize persistent software block state
- * @rfkill: pointer to the rfkill class to modify.
- * @state: the current software block state to set
- *
- * rfkill drivers that preserve their software block state over power off
- * use this function to notify the rfkill core (and through that also
- * userspace) of their initial state. It should only be used before
- * registration.
- *
- * In addition, it marks the device as "persistent", an attribute which
- * can be read by userspace. Persistent devices are expected to preserve
- * their own state when suspended.
- */
-void rfkill_init_sw_state(struct rfkill *rfkill, bool blocked);
-
-/**
- * rfkill_set_states - Set the internal rfkill block states
- * @rfkill: pointer to the rfkill class to modify.
- * @sw: the current software block state to set
- * @hw: the current hardware block state to set
- *
- * This function can be called in any context, even from within rfkill
- * callbacks.
- */
-void rfkill_set_states(struct rfkill *rfkill, bool sw, bool hw);
-
-/**
- * rfkill_blocked - query rfkill block
- *
- * @rfkill: rfkill struct to query
- */
-bool rfkill_blocked(struct rfkill *rfkill);
-#else /* !RFKILL */
-static inline struct rfkill * __must_check
-rfkill_alloc(const char *name,
- struct device *parent,
- const enum rfkill_type type,
- const struct rfkill_ops *ops,
- void *ops_data)
-{
- return ERR_PTR(-ENODEV);
-}
-
-static inline int __must_check rfkill_register(struct rfkill *rfkill)
-{
- if (rfkill == ERR_PTR(-ENODEV))
- return 0;
- return -EINVAL;
-}
-
-static inline void rfkill_pause_polling(struct rfkill *rfkill)
-{
-}
-
-static inline void rfkill_resume_polling(struct rfkill *rfkill)
-{
-}
-
-static inline void rfkill_unregister(struct rfkill *rfkill)
-{
-}
-
-static inline void rfkill_destroy(struct rfkill *rfkill)
-{
-}
-
-static inline bool rfkill_set_hw_state(struct rfkill *rfkill, bool blocked)
-{
- return blocked;
-}
-
-static inline bool rfkill_set_sw_state(struct rfkill *rfkill, bool blocked)
-{
- return blocked;
-}
-
-static inline void rfkill_init_sw_state(struct rfkill *rfkill, bool blocked)
-{
-}
-
-static inline void rfkill_set_states(struct rfkill *rfkill, bool sw, bool hw)
-{
-}
-
-static inline bool rfkill_blocked(struct rfkill *rfkill)
-{
- return false;
-}
-#endif /* RFKILL || RFKILL_MODULE */
-
-
-#ifdef CONFIG_RFKILL_LEDS
-/**
- * rfkill_get_led_trigger_name - Get the LED trigger name for the button's LED.
- * This function might return a NULL pointer if registering of the
- * LED trigger failed. Use this as "default_trigger" for the LED.
- */
-const char *rfkill_get_led_trigger_name(struct rfkill *rfkill);
-
-/**
- * rfkill_set_led_trigger_name -- set the LED trigger name
- * @rfkill: rfkill struct
- * @name: LED trigger name
- *
- * This function sets the LED trigger name of the radio LED
- * trigger that rfkill creates. It is optional, but if called
- * must be called before rfkill_register() to be effective.
- */
-void rfkill_set_led_trigger_name(struct rfkill *rfkill, const char *name);
-#else
-static inline const char *rfkill_get_led_trigger_name(struct rfkill *rfkill)
-{
- return NULL;
-}
-
-static inline void
-rfkill_set_led_trigger_name(struct rfkill *rfkill, const char *name)
-{
-}
-#endif
-
-#endif /* __KERNEL__ */
-#endif /* RFKILL_H */
+#endif /* _UAPI__RFKILL_H */
--
cgit v1.2.1

View File

@@ -0,0 +1,134 @@
# Added for Squid accounting
%tr = (
%tr,
'acct action' => 'Action',
'acct activate' => 'Activer',
'acct addresses' => 'Gestion des adresses',
'acct bank' => 'Banque',
'acct bic' => 'BIC',
'acct billarchive' => 'Archivage des factures',
'acct billgroup' => 'Facturation groupée',
'acct billgroupexists' => 'Un groupe de facturation avec ce nom existe déjà',
'acct billtext1' => 'Texte de la facture',
'acct billnr' => '(numero de facture)',
'acct billoverview' => 'Aperçu de la facture',
'acct blz' => 'Code banque',
'acct ccmail' => 'Adresses email CC',
'acct currency' => 'Devise (EUR, USD)',
'acct traffic' => 'Trafic',
'acct amount' => 'Quantite',
'acct cent' => 'Tarif / Mo (ex. : 0,003)',
'acct cent1' => 'Tarif / Mo',
'acct city' => 'Ville',
'acct config' => 'Configuration',
'acct commit' => 'Exécuter',
'acct company' => 'Société',
'acct companyexists' => 'Une société avec ce nom existe déjà',
'acct companytype' => 'Type',
'acct customer' => 'Client',
'acct cust empty' => 'Aucune adresse client définie',
'acct dbsize' => 'Taille de la base de données',
'acct dbmaintenance' => 'Maintenance de la base de données',
'acct delbefore' => 'Supprimer toutes les entrées avant la période définie',
'acct deladr' => 'Supprimer',
'acct edit' => 'Modifier',
'acct edit_addr' => 'Ajouter / Modifier',
'acct email' => 'Email',
'acct emptydb' => 'Effacer la base de données (toutes les données)',
'acct emptydbtraf' => 'Effacer la base de données (données de trafic uniquement)',
'acct empty field' => 'Le champ ne doit pas être vide : ',
'acct entries' => 'Entrées',
'acct err custdel' => 'L\'adresse ne peut pas être supprimée. Elle est définie comme client dans un groupe de factures - Groupe de factures',
'acct err hostdel' => 'L\'adresse ne peut pas être supprimée. Elle est définie comme fournisseur dans un groupe de factures - Groupe de factures',
'acct exst_cust_addr' => 'Adresses de clients',
'acct exst_host_addr' => 'Adresse de fournisseur',
'acct expert' => 'Activer les options de maintenance',
'acct expdelbefore' => 'Supprimer',
'acct fax' => 'Fax',
'acct fix billpos' => 'Ajout manuel de facturation pour le groupe',
'acct gb' => 'Go',
'acct generated' => 'Généré',
'acct hint billgrp' => 'Vous devez d\'abord définir un fournisseur et une adresse client',
'acct hint_hoster' => 'Ne doit être rempli que lorsque le type est "fournisseur" ',
'acct hrb' => 'No-HRB',
'acct hoster' => 'Fournisseur',
'acct hosts' => 'Détails des hôtes',
'acct host empty' => 'Aucune adresse de fournisseur définie',
'acct host detail' => 'Détails de l\'hôte',
'acct iban' => 'IBAN',
'acct inet' => 'Internet',
'acct interval' => 'Checkintervall',
'acct invalid' => 'Valeur invalide pour',
'acct invalid billpos' => 'Vous devez remplir tous les champs pour les postes de facturation fixes',
'acct invalid mailip' => 'Adresse IP invalide pour le serveur de messagerie',
'acct invalid mailfqdn' => 'Nom de domaine invalide pour le serveur de messagerie',
'acct invalid mailport' => 'Port invalide pour le serveur de messagerie',
'acct invalid png' => 'Fichier PNG invalide',
'acct invalid pngsize' => 'Taille PNG invalide',
'acct kb' => 'Ko',
'acct kto' => 'No. de compte',
'acct latestdb' => 'Dernière entrée en base de données',
'acct logging' => 'Activer la journalisation (/var/log/accounting.log)',
'acct logo' => 'Logo actuel',
'acct logo upload' => 'Télécharger logo (PNG, 400x150 max.)',
'acct maintenance' => 'Maintenance',
'acct mailaddr' => 'Adresse du serveur de mail',
'acct mailport' => 'Port du serveur de mail',
'acct mailuser' => 'Nom utilsateur',
'acct mailpass' => 'Mot de passe',
'acct mailrcpt' => 'Adresse email destinataire',
'acct mailsender' => 'Adresse email expéditeur',
'acct mailtxt' => 'Texte de la facture par mail',
'acct mb' => 'Mo',
'acct members' => 'Hôtes',
'acct menu' => 'Comptes utilisateurs de proxy',
'acct month' => 'Mois',
'acct multiuser' => 'Utilisateur possible dans plusieurs groupes',
'acct mwst_name' => 'TVA',
'acct mwst' => 'Taux de TVA (%)',
'acct name1' => 'Nom 1',
'acct name2' => 'Nom 2',
'acct nr' => 'No-RG',
'acct oldestdb' => 'Première entrée en base de données',
'acct not optional' => 'Champs requis',
'acct parameter' => 'Paramètre',
'acct path' => 'Chemin',
'acct pdf billtxt' => 'Facture',
'acct pdf date' => 'Date',
'acct pdf zwsum' => 'sous-total',
'acct pdf page' => 'Page',
'acct pdf prov' => 'Expéditeur',
'acct pdf sum1' => 'Sous-total',
'acct pdf price' => 'Tarif',
'acct pdf time' => 'Periode',
'acct plz' => 'Code postal',
'acct preview' => 'Prévisualisation de la facture',
'acct price pp' => 'Tarif unitaire',
'acct proxy_enable' => 'Veuillez d\'abord activer le proxy',
'acct pos' => 'Pos.',
'acct sum total' => 'Total',
'acct name' => 'Description',
'acct no data' => 'Aucune donnée disponible',
'acct rrdsize' => 'Taille du dossier des factures',
'acct settings' => 'Paramètres de comptes',
'acct skipurl' => 'Ignorer ces URL (Intranet)',
'acct status' => 'Statut',
'acct str' => 'Rue',
'acct str_nr' => 'Numéro',
'acct subject' => 'Sujet',
'acct sum' => 'Total',
'acct task' => 'Tâche',
'acct tb' => 'To',
'acct tel' => 'Téléphone',
'acct tls' => 'Utiliser TLS',
'acct traffic monthly' => 'Volume cumulé de données mensuel',
'acct title' => 'Comptes de proxy web',
'acct usemail' => 'Envoi de la facture par mail',
'acct usermulti' => 'est déjà dans le groupe',
'acct ustid' => 'Id-USt',
'acct edit settings' => 'Modifier paramètres',
'acct value' => 'Valeur',
'acct view' => 'Afficher',
'acct year' => 'Année'
);
# End Squid accounting

View File

@@ -17,7 +17,7 @@ done
function _strip() {
local file=${1}
local cmd="${STRIP-strip}"
local strip="${STRIP-strip}"
local exclude l
for exclude in ${excludes}; do
@@ -27,17 +27,19 @@ function _strip() {
fi
done
local cmd=( "${strip}" )
case "$(file -bi ${file})" in
application/x-sharedlib*|application/x-archive*)
cmd="${cmd} --strip-debug --remove-section=.comment --remove-section=.note"
application/x-archive*)
cmd+=( "--strip-debug" "--remove-section=.comment" "--remove-section=.note" )
;;
*)
cmd="${cmd} --strip-unneeded"
cmd+=( "--strip-all" )
;;
esac
echo "Stripping ${file}..."
${cmd} ${file}
${cmd[*]} ${file}
}
for dir in ${dirs}; do