Projet

Général

Profil

Révision a639d4b4

IDa639d4b447acc7e46ab05e4f3b7b9b307979bd2d
Parent 81c1afa7
Enfant 3706fe00

Ajouté par Lars Kruse il y a plus de 7 ans

travis: explain change of perl environment

more details can be found in the discussion regarding this change:
https://github.com/munin-monitoring/contrib/pull/853

Voir les différences:

.travis.yml
8 8
  - sudo apt-get --no-install-recommends install munin-node
9 9
  - sudo apt-get --no-install-recommends install libsys-virt-perl
10 10

  
11
  # we use locally installed cpan modules instead of travis' builtin 'homebrew' perl support
12
  # The homebrew variation does not work for us, since:
13
  #   * it is built without threading
14
  #   * the 'libvirt' plugin requires Sys::Virt, which is not available via cpan anymore - thus we need to install the Debian package 'libsys-virt-perl', which was built with threading
11 15
  - cpanm --local-lib=~/perl5 local::lib && eval $(perl -I ~/perl5/lib/perl5/ -Mlocal::lib)
12 16

  
13 17
  # Modules used by test script
......
61 65
  # - VMware::VIRuntime
62 66
  # - MythTV
63 67

  
64
# Mixing modules installed via cpan and apt is a bit problematic:
65
#   * perl (as it is used by travis) seems to be built without threading support
66
#   * perl modules installed via apt were built against a threaded perl (e.g. DBI/DBI.so)
67
# Thus we need to make sure, that the modules installed via CPAN and the binary modules prepared by
68
# travis are preferred over the binary perl modules installed via apt (e.g. below /usr/lib/perl).
69
# Since the PERL5LIB environment variable precedes all other search paths, we use the sequence
70
# below in order to achieve the following order of preference:
71
#   1) /usr/share/perl5 (unknown requirement)
72
#   2) perl search path defined by travis environment
73
#   3) binary system-wide installed perl modules (via apt)
74 68
script:
75
  - dpkg -L libsys-virt-perl
76
  - mkdir -p ~/system-perl/auto
77
  - ln -s /usr/lib/perl5/Sys ~/system-perl/
78
  - ln -s /usr/lib/perl5/auto/Sys ~/system-perl/auto/
79
  - "PERL5LIB=$PERL5LIB:/usr/share/perl5:~/system-perl prove"
69
  - prove

Formats disponibles : Unified diff