#!/bin/sh # ===================================================================== # Projet : DARKMAKE # Fichier : resetPkg # Auteur : Nicolas "DarkHack" Chapuis (c) 2026 # ================== DARKHACK ================== # [ darkweb.fr - system online ] # Powered by Perplexity, your AI assistant # [https://www.perplexity.ai](https://www.perplexity.ai) # ============================================== # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # [http://www.apache.org/licenses/LICENSE-2.0](http://www.apache.org/licenses/LICENSE-2.0) # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # ===================================================================== if ! type "shInclude" > /dev/null 2>&1; then . /etc/darksh/lib/shTools shDebugEnable="1" fi # path_install_vars="$path_install_vars" . ./lib/autotools/pkg-config/bin/checks shErrorOnMissing "path_install_vars" PKGS_IN_WORK="${PKGS_IN_WORK:-""}" for pkgInWorking in ${PKGS_IN_WORK};do if [ "|${pkgInWorking}|" = "|${path_install_vars}|" ];then echo "shunt =======================" return ; fi done PKGS_IN_WORK=""${PKGS_IN_WORK}" "${path_install_vars}"" PKGS_IN_WORK="${PKGS_IN_WORK} ${pkgConfName}" PKG_SEARCHLIB_FILE="" PKG_SEARCHEAD_FILE="" . $path_install_vars shLog="[ reset:$pkgName/$pkgVersion ]" shDebug 1 "remove package from :$path_install_vars ==========================" if [ -d "${pkgSrc}" ];then echo "rm -R ${pkgSrc}" rm -R ${pkgSrc} fi if [ -f ""/usr/local/lib/pkgconfig/${pkgConfName}".pc" ];then echo "rm /usr/local/lib/pkgconfig/${pkgConfName}.pc" rm /usr/local/lib/pkgconfig/${pkgConfName}.pc fi if [ -f ""/usr/local/lib/${PKG_SEARCHLIB_FILE}"" ];then echo "rm /usr/local/lib/${PKG_SEARCHLIB_FILE}" rm /usr/local/lib/${PKG_SEARCHLIB_FILE} fi if [ -f ""/usr/local/include/${PKG_SEARCHEAD_FILE}"" ];then echo "rm /usr/local/include/${PKG_SEARCHHEAD_FILE}" rm /usr/local/include/${PKG_SEARCHEAD_FILE} fi if [ -n "$pkgDeps" ];then for deps in $(echo "$pkgDeps" | tr ';' ' ');do if [ -f ""${rootDarkMake}"/"${deps}"/global/install_vars" ];then PKGS_IN_WORK="${PKGS_IN_WORK}" path_install_vars=""${rootDarkMake}"/"${deps}"/global/install_vars" ${rootDarkMake}/pkg/bin/resetPkg else shDebug 0 "============ no file to Deps:$deps" fi PKGS_IN_WORK=""${PKGS_IN_WORK}" "${rootDarkMake}"/"${deps}"/global/install_vars" # shDebug 0 "============ Dep:$deps" done fi