Commit 204ec0233a2ae5e7714279268430eb9aef96076c

Thomas de Grivel 2023-09-15T14:02:10

rbpkg/etc/rbpkg.rb

diff --git a/etc/profile b/etc/profile
index 64ebde5..4fca22b 100644
--- a/etc/profile
+++ b/etc/profile
@@ -13,7 +13,3 @@ export LD_LIBRARY_PATH="${RBPKG_DIR}/lib:${LD_LIBRARY_PATH}"
 export CPPFLAGS="${CPPFLAGS} -I${RBPKG_DIR}/include"
 export LDFLAGS="${LDFLAGS} -L${RBPKG_DIR}/lib"
 export PKG_CONFIG_PATH="${RBPKG_DIR}/lib/pkgconfig"
-
-if [ -f "${RBPKG_DIR}/etc/profile.local" ]; then
-    . "${RBPKG_DIR}/etc/profile.local"
-fi
diff --git a/lib/rbpkg.rb b/lib/rbpkg.rb
index 6892450..d7b41b7 100644
--- a/lib/rbpkg.rb
+++ b/lib/rbpkg.rb
@@ -2,6 +2,10 @@ require 'time'
 load "#{File.dirname(__FILE__)}/rbpkg/log.rb"
 load "#{File.dirname(__FILE__)}/rbpkg/repos.rb"
 
+if File.exist?("#{File.dirname(File.dirname(__FILE__))}/etc/rbpkg.rb")
+  load "#{File.dirname(File.dirname(__FILE__))}/etc/rbpkg.rb"
+end
+
 module Rbpkg
   def self.build(repos)
     repos.each do |name|