phusion / passenger

A fast and robust web server and application server for Ruby, Python and Node.js
https://www.phusionpassenger.com/
MIT License
4.99k stars 548 forks source link

[6.0.14] pid_t typedef unknown OR getpid() return value ambiguous on Solaris 11.4 compilation #2441

Open danowar2k opened 2 years ago

danowar2k commented 2 years ago

Issue report

After a local patch fixing my last issue https://github.com/phusion/passenger/issues/2440, the next error I encounter is the following (excerpt of the build output):

Creating src/apache2_module/DirConfig/AutoGeneratedHeaderSerialization.cpp
/usr/bin/g++ -m32 -o buildout/apache2/Hooks.o  -Isrc/agent -Isrc/cxx_supportlib -Isrc/cxx_supportlib/vendor-copy -Isrc/cxx_supportlib/vendor-modified -fPIC -DSOLARIS2=11 -D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT -D_LARGEFILE64_SOURCE -I/app/tools/apache2/2.4.53/include -I/app/tools/apache2/2.4.53/include -I/app/tools/apache2/2.4.53/include -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -ggdb -std=gnu++11 -Wno-unused-local-typedefs -Wno-format-nonliteral -DHAS_UNORDERED_MAP -pthreads -D__EXTENSIONS__ -D__SOLARIS__ -D_FILE_OFFSET_BITS=64 -DBOOST_HAS_STDINT_H -c src/apache2_module/Hooks.cpp
[...]
In file included from src/apache2_module/Hooks.cpp:74:0:
src/cxx_supportlib/WatchdogLauncher.h: In member function ‘void Passenger::WatchdogLauncher::start(const string&, const Passenger::Json::Value&, const boost::function<void()>&)’:
src/cxx_supportlib/WatchdogLauncher.h:333:53: error: conversion from ‘pid_t {aka long int}’ to ‘Passenger::Json::Value’ is ambiguous
   config["web_server_control_process_pid"] = getpid();
                                                     ^
In file included from src/cxx_supportlib/LoggingKit/Forward.h:30:0,
                 from src/cxx_supportlib/LoggingKit/LoggingKit.h:29,
                 from src/cxx_supportlib/FileDescriptor.h:38,
                 from src/apache2_module/Bucket.h:31,
                 from src/apache2_module/Hooks.cpp:58:
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:763:3: note: candidate: Passenger::Json::Value::Value(bool)
   Value(bool value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:740:3: note: candidate: Passenger::Json::Value::Value(double)
   Value(double value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:738:3: note: candidate: Passenger::Json::Value::Value(Passenger::Json::Value::UInt64)
   Value(UInt64 value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:737:3: note: candidate: Passenger::Json::Value::Value(Passenger::Json::Value::Int64)
   Value(Int64 value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:735:3: note: candidate: Passenger::Json::Value::Value(Passenger::Json::Value::UInt)
   Value(UInt value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:734:3: note: candidate: Passenger::Json::Value::Value(Passenger::Json::Value::Int)
   Value(Int value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:774:10: note:   initializing argument 1 of ‘Passenger::Json::Value& Passenger::Json::Value::operator=(Passenger::Json::Value)’
   Value& operator=(Value other);
          ^~~~~~~~
rake aborted!
Command failed with status (1): [/usr/bin/g++ -m32 -o buildout/apache2/Hooks.o  -Isrc/agent -Isrc/cxx_supportlib -Isrc/cxx_supportlib/vendor-copy -Isrc/cxx_supportlib/vendor-modified -fPIC -DSOLARIS2=11 -D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT -D_LARGEFILE64_SOURCE -I/app/tools/apache2/2.4.53/include -I/app/tools/apache2/2.4.53/include -I/app/tools/apache2/2.4.53/include -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -ggdb -std=gnu++11 -Wno-unused-local-typedefs -Wno-format-nonliteral -DHAS_UNORDERED_MAP -pthreads -D__EXTENSIONS__ -D__SOLARIS__ -D_FILE_OFFSET_BITS=64 -DBOOST_HAS_STDINT_H -c src/apache2_module/Hooks.cpp]
/app/tools/redmine/3.3.0/.appgems/ruby/2.3.0/gems/passenger-6.0.14/build/support/cplusplus.rb:53:in `run_compiler'
/app/tools/redmine/3.3.0/.appgems/ruby/2.3.0/gems/passenger-6.0.14/build/support/cplusplus.rb:104:in `compile_cxx'
/app/tools/redmine/3.3.0/.appgems/ruby/2.3.0/gems/passenger-6.0.14/build/support/cplusplus.rb:162:in `block in define_cxx_object_compilation_task'
/app/tools/redmine/3.3.0/.appgems/ruby/2.3.0/gems/rake-13.0.6/exe/rake:27:in `<top (required)>'
Tasks: TOP => apache2 => buildout/apache2/mod_passenger.so => buildout/apache2/Hooks.o
(See full trace by running task with --trace)

I limited the output above to the error in question, the other warnings don't seem pertinent to that error. Of course I can always post/attach the whole log if necessary.

Question 1: What is the problem?

The above error. It looks like the line https://github.com/phusion/passenger/blob/stable-6.0/src/cxx_supportlib/WatchdogLauncher.h#L333 is the problem. getpid() returns an ambiguous pid_t structure which is probably a Solaris problem again ...? Anyway, the compiler doesn't know what pid_t is supposed to be at that time (or it looks like it anyway). So it doesn't know which overloaded function to call. The object at least compiled when I cast pid_t to an integer (or an unsigned integer), but of course I don't know if this could be a fix:

config["web_server_control_process_pid"] = (int) getpid();

Question 2: Passenger version and integration mode:

Passenger open source 6.0.14 running on Ruby 2.3.8 (yeah, sorry, I'm trying to fix this right now) against a self-compiled 32 Bit Apache httpd 2.4.53 to build mod_passenger.

Question 3: OS or Linux distro, platform (including version):

Solaris 11.4 Release, x86_64

Question 4: Passenger installation method:

Your answer: [x] RubyGems + Gemfile (Gemfile.local for Redmine 3.3.0)

Question 5: Your app's programming language (including any version managers) and framework (including versions):

Ruby 2.3.8 without RVM, Rails 4.2.6

Question 6: Are you using a PaaS and/or containerization? If so which one?

No containerization. Using Vagrant 2.2.16 + VirtualBox 6.1.22 plus private Vagrant boxes.

Question 7: Anything else about your setup that we should know?

No, I think.

danowar2k commented 2 years ago

Sorry, my comments were made on the wrong issue. I'll just copy them over here...

Additional info:

On Solaris 11, pid_t is defined in /usr/include/sys/types.h as an int (see https://docs.oracle.com/cd/E86824_01/html/E54772/types.h-3head.html)

I don't know if Passenger includes that on Solaris or if that is some Solaris-special snowflake place.

Maybe the problem is that the getpid() function declaration is unclear as to what getpid() returns...hmm.

Another instance where the same error basically happens later:

In file included from src/agent/Core/SpawningKit/SmartSpawner.h:62:0,
                 from src/agent/Core/SpawningKit/Factory.h:30,
                 from src/agent/Core/ApplicationPool/Context.h:33,
                 from src/agent/Core/ApplicationPool/Common.h:40,
                 from src/agent/Core/ApplicationPool/Pool.h:62,
                 from src/agent/Core/Controller/Request.h:37,
                 from src/agent/Core/Controller/Client.h:32,
                 from src/agent/Core/Controller.h:83,
                 from src/agent/Core/TelemetryCollector.h:45,
                 from src/agent/Core/Config.h:47,
                 from src/agent/Watchdog/Config.h:32,
                 from src/agent/Watchdog/WatchdogMain.cpp:68:
src/agent/Core/SpawningKit/Exceptions.h: In member function ‘Passenger::Json::Value Passenger::SpawningKit::SpawnException::inspectSubprocessDetailsAsJson() const’:
src/agent/Core/SpawningKit/Exceptions.h:1057:34: error: conversion from ‘pid_t {aka long int}’ to ‘Passenger::Json::Value’ is ambiguous
    doc["pid"] = getSubprocessPid();

Maybe I should reevaluate my approach and just try to flee to RHEL.

CamJN commented 2 years ago

Ok, i think that the ambiguity in the sources is due to solaris seemingly having a 64 bit pid_t, which is different than the platforms we usually deal with. I'll look into fixing this when i have a second.

danowar2k commented 2 years ago

More info from my side (I hope):

For compilation, I use gcc 7.x (common denominator between Solaris 11.4.0 (Release) and current supported Solaris 11.4.x), always with the -m32 switch added (No substantial reason for that, though). I've always had many problems when compiling 64 bit stuff on Solaris 11.

I think I do this because some Python libraries were 32 bit only and my compile sessions boiled down to "build this 64 bit, build that 64 bit, build the xth tool dependency in 64 bit...oops that won't work, time to go back to the drawing board."

My Ruby 2.3.8 and Apache httpd 2.4.53 are self-compiled 32 bit versions using the same gcc version, if that's any info that helps. Maybe the pid_t 64/32 bit values are scrambled/overwritten because I forgot some CFLAGS/etc. switch?

danowar2k commented 2 years ago

Ok, i think that the ambiguity in the sources is due to solaris seemingly having a 64 bit pid_t, which is different than the platforms we usually deal with. I'll look into fixing this when i have a second.

I could check that if you gave me a hint how to (not a C/C++ developer, though)

CamJN commented 2 years ago

Ugh I forgot how byzantine solaris is, and how all the docs are paywalled. You wouldn't happen to have a link to a guide to setup a dev environment on solaris?

danowar2k commented 2 years ago

I can always try to help you doing this, you know.

I use VirtualBox and Vagrant and you could use this Vagrant box here as a basis: https://app.vagrantup.com/MartijnDwars/boxes/solaris11_4

I could help you with an Ansible role building Ruby 2.3.8. And you don't even need httpd 2.4.53, I think Passenger standalone compilation has the same problems...

danowar2k commented 2 years ago

What exactly do you need to be setup once you have a running Solaris 11.4? mdb, gcc, something else?

EDIT: I'm in Germany, so we'd have to work around the time difference factor ;-)

CamJN commented 2 years ago

I'll need to get git and a c++ compiler installed at least, also I'm not sure if I understand the docs right, is the solaris IPS the local repo that comes with the solaris download and which you have to setup yourself? or is that another repo? I've figured out that the online solaris repo requires some paid subscription. I do seem to have access to solarisstudio which is described as "Access to the Oracle Studio C, C++, and Fortran tools", but I don't know if they mean a compiler suite or an IDE I don't need.

CamJN commented 2 years ago

Ok, it looks like the local repo is indeed the "solaris" repo, and it seems to have both git and gcc so that's good, on the downside the "verification" step apparently takes ages so i'll probably have to leave this overnight.

CamJN commented 2 years ago

Ok, good news and bad news. The good news is that I managed to build the (new) passenger repo HEAD commit on Solaris 11.4 using the default gcc/git/ruby packages. The bad news is that I didn't have to fix the error you are seeing so I'm not confident that it'll be fixed for you.

Here's what I ran once I got pkg install working:

  sudo pkg install developer/versioning/git
  sudo pkg install runtime/ruby
  git clone https://github.com/phusion/passenger.git
  cd passenger/
  git submodule init
  git submodule update
  sudo gem install rake --no-document
  sudo pkg install 'developer/gcc'
  rake apache2
  rake nginx

Here's the versions that pkg gave me:

camden@solaris:~/passenger$ pkg info developer/versioning/git
             Name: developer/versioning/git
          Summary: git - Fast Version Control System
      Description: Git is a free & open source, distributed version control
                   system designed to handle everything from small to very large
                   projects with speed and efficiency.
         Category: Development/Source Code Management
            State: Installed
        Publisher: solaris
          Version: 2.31.1
           Branch: 11.4.42.0.0.111.0
   Packaging Date: December  3, 2021 at  7:51:47 PM
Last Install Time: September 10, 2022 at  9:13:06 PM
             Size: 32.94 MB
             FMRI: pkg://solaris/developer/versioning/git@2.31.1-11.4.42.0.0.111.0:20211203T195147Z
      Project URL: http://git-scm.com/
       Source URL: https://www.kernel.org/pub/software/scm/git/git-2.31.1.tar.xz
camden@solaris:~/passenger$ pkg info runtime/ruby
             Name: runtime/ruby
          Summary: Ruby, RubyGems, and Rake
      Description: Metapackage that ensures at least one version of Ruby is
                   installed
         Category: Development/Ruby
            State: Installed
        Publisher: solaris
          Version: 2.6
           Branch: 11.4.42.0.0.111.0
   Packaging Date: December  3, 2021 at  8:53:52 PM
Last Install Time: September 10, 2022 at  9:19:07 PM
             Size: 2.52 kB
             FMRI: pkg://solaris/runtime/ruby@2.6-11.4.42.0.0.111.0:20211203T205352Z
      Project URL: http://www.ruby-lang.org/
camden@solaris:~/passenger$ pkg info 'developer/gcc'
             Name: developer/gcc
          Summary: GCC
         Category: Development/C (org.opensolaris.category.2008) Development/C++
                   (org.opensolaris.category.2008) Development/Fortran
                   (org.opensolaris.category.2008) Development/GNU
                   (org.opensolaris.category.2008) Development/Objective C
                   (org.opensolaris.category.2008)
            State: Installed
        Publisher: solaris
          Version: 11.2.0
           Branch: 11.4.42.0.0.111.0
   Packaging Date: December  3, 2021 at  7:31:27 PM
Last Install Time: September 10, 2022 at  9:23:27 PM
             Size: 2.52 kB
             FMRI: pkg://solaris/developer/gcc@11.2.0-11.4.42.0.0.111.0:20211203T193127Z
      Project URL: https://gcc.gnu.org/
       Source URL: https://ftp.gnu.org/gnu/gcc/gcc-11.2.0/gcc-11.2.0.tar.gz
danowar2k commented 2 years ago

Okay, there are some things that seem strange to me if you're working on a Solaris 11.4 machine not subscribed to receive SRU packages (patches and new package versions released after the release version Solaris 11.4.0).

Our infrastructure is able to use the Support repository, our dev VMs aren't, because there isn't such a thing analog to e.g. the RedHat Developer License on Solaris. The repository where our dev VMs get the packages is called the Release repository. Both the Release and Support repository are online package repositories.

So, I'm gonna check some things and post the output here and it would help greatly if you'd do the same so that I can see what's happening.

IPS is the packaging system on Solaris 11, which you use with the pkg command. Solaris 10 had various commands, pkgchk, pkginfo etc. etc.

Questions open:

danowar2k commented 2 years ago

Okay, it seems

# First check the version
vagrant@dev-redmine:~$ uname -a
SunOS dev-redmine 5.11 11.4.0.15.0 i86pc i386 i86pc
# Check the currently active package repositories for this machine
vagrant@dev-redmine:~$ pkg publisher
PUBLISHER                   TYPE     STATUS P LOCATION
solaris                     origin   online F http://pkg.oracle.com/solaris/release/
# Okay, that's the Release package repository. You should have that, too, as the only publisher.
# Now check what of the above packages I could install... -a means available packages
vagrant@dev-redmine:~$ pkg list -a | grep git
developer/versioning/git                          2.15.2-11.4.0.0.1.14.0     i--
[...]
vagrant@dev-redmine:~$ pkg list -a | grep gcc
SUNWgcc                                           3.4.3-11.4.0.0.0.14.0      --o
SUNWgccruntime                                    3.4.3-11.4.0.0.0.14.0      --o
developer/gcc                                     7.3.0-11.4.0.0.1.14.0      ---
developer/gcc-10                                  10.3.0-11.4.42.0.0.111.0   ---
developer/gcc-11                                  11.2.0-11.4.42.0.0.111.0   ---
[...]
developer/gcc-5                                   5.5.0-11.4.0.0.1.14.0      ---
developer/gcc-7                                   7.3.0-11.4.0.0.1.14.0      i--
developer/gcc-9                                   9.4.0-11.4.42.0.0.111.0    ---
[...]
# I do not list the c compiler and c++ compiler packages, because they are similar.
# Finally, ruby...
vagrant@dev-redmine:~$ pkg list -a | grep ruby
[...]
runtime/ruby                                      2.1-11.4.0.0.1.14.0        ---
runtime/ruby-18                                   1.8.7.374-11.4.0.0.1.9.0   --o
runtime/ruby-19                                   1.9.3.551-11.4.0.0.1.9.0   --o
runtime/ruby-19/ruby-tk                           1.9.3.551-11.4.0.0.1.9.0   --o
runtime/ruby-21                                   2.1.6-11.4.0.0.1.14.0      ---
runtime/ruby-21/ruby-tk                           2.1.6-11.4.0.0.1.14.0      ---
runtime/ruby-23                                   2.3.1-11.4.0.0.1.14.0      ---
runtime/ruby-23/ruby-tk                           2.3.1-11.4.0.0.1.14.0      ---
runtime/ruby-25                                   2.5.9-11.4.39.0.1.107.0    --o
runtime/ruby-26                                   2.6.8-11.4.42.0.0.111.0    ---

I found something that maybe explains the .42 versions: https://blogs.oracle.com/solaris/post/announcing-the-first-oracle-solaris-114-cbe

It seems Oracle finally decided to release an update for 11.4 that is usable for developers without a support license and you installed a VM containing this. It also seems that the update is integrated into the Release package repository but I never bothered to look for that. I have to maybe update my dev VM Packer image to incorporate this update, it seems, to avoid confusion like we have now.

The "42/CBE" update let's me finally be able to use GCC 9 to 11 on the dev VM so that we can switch to that in production, yay!

Anyway, this potentially could influence whether I get the bug or not...

Another difference is that you installed Ruby 2.6, but I didn't even use a Solaris package, but self-compiled Ruby 2.3.8. Maybe the error would come up if you instead install the ruby-2.3 package, maybe not. I'm currently wondering why I even self-compile Ruby 2.3.8 instead of just using the packaged version, though. Possibly because the ruby-2.3 package is Ruby 2.3.1, or so it seems, instead of the latest 2.3.8.

Just in case you'd like to completely reproduce my error, here are my steps for that:

# From a fresh VM, self-compiling Ruby 2.3.8 etc.
sudo pkg install developer/versioning/git
sudo pkg install gcc-7
sudo pkg install gnu-tar
sudo pkg install pkg:/text/gawk
sudo pkg install gnu-binutils

# compile Ruby 2.3.8
wget https://cache.ruby-lang.org/pub/ruby/ruby-2.3.8.tar.gz
gtar -xzvf ruby-2.3.8.tar.gz
cd ruby-2.3.8
# to use GNU awk
export AWK=/usr/bin/gawk
# to build 32 bit
export CC="/usr/bin/gcc -m32"
export CXX="/usr/bin/g++ -m32"
# to use GNU nm
export NM=/usr/bin/gnm
# compile Ruby 2.3.8 32 Bit Solaris binaries
# --enable-shared | Build ruby with shared libraries
# --without-X11 | Build ruby without X11 support (unnecessary on server)
/usr/bin/gmake distclean
bash ./configure --build=i386-pc-solaris2.11 --prefix=~/ruby-2.3.8 --enable-shared --without-X11
# compile with paralel jobs
/usr/bin/gmake -j 10 -l 3.5
/usr/bin/gmake install

# Now use that ruby
export PATH=/export/home/vagrant/ruby-2.3.8/bin:${PATH}
# Back to home...
cd ~
# Reproduce your steps
git clone https://github.com/phusion/passenger.git
cd passenger/
git submodule init
git submodule update
sudo gem install rake --no-document
# I guess this compiles the apache2 module
rake apache2

Now, I haven't done the steps after compiling Ruby 2.3.8 myself. Instead I used https://www.phusionpassenger.com/docs/tutorials/deploy_to_production/installations/oss/ownserver/ruby/apache/ (OS independent + Rubygems without RVM). Or rather, the passenger-install-apache2-module.

My next steps for this will be to update the Packer Solaris image to CBE/42 and use that as a base image. Then I'll test the above method (self-compiling Ruby 2.3.8, then cloning Passenger etc.) I'll report back.

danowar2k commented 2 years ago

One question is still open: What base for Solaris did you use now? A Vagrant box? I'd like to use the same box as you to prevent any more differences.

CamJN commented 2 years ago

I used the Oracle Solaris 11.4 Common Build Environment 11.4.42 files to create a solaris vm in vmware (2cpus, 8GB ram, 60GB storage minimum or solaris blows up), specifically the Interactive Text Install ISO. I then copied the remaining files into the vm and used the IPS Repository Assembly Script to create a local repo from which i could install packages (during this process of creating the repo it optionally "verifies" all 8k+ repo packages, one at a time, which took a lot longer than I expected), and added it as a source for the solaris repo. I then disabled the existing url source for the solaris repo as it pointed to the Oracle Solaris support repository which requires a paid subscription, and i didn't know about the free Oracle Solaris release repository. I was then able to install the packages I listed. I've got the vm off atm to do some other work, i'll reply again with the output of those commands above when i turn it back on.

CamJN commented 2 years ago
camden@solaris:~/passenger$ uname -a
SunOS solaris 5.11 11.4.42.111.0 i86pc i386 i86pc vmware
camden@solaris:~/passenger$ pkg publisher
PUBLISHER                   TYPE     STATUS P LOCATION
solaris                     origin   online F file:///var/share/pkg/repositories/
camden@solaris:~/passenger$ pkg publisher solaris

            Publisher: solaris
                Alias: 
           Origin URI: file:///var/share/pkg/repositories/
        Origin Status: Online
              SSL Key: None
             SSL Cert: None
          Client UUID: 55fb084a-54c9-11ec-95d5-7f83bd53beb4
      Catalog Updated: December  7, 2021 at  2:46:53 AM 
    Publisher enabled: Yes
camden@solaris:~/passenger$ pkg list -a '*git*'
NAME (PUBLISHER)                                  VERSION                    IFO
developer/versioning/git                          2.31.1-11.4.42.0.0.111.0   i--
developer/versioning/mercurial/hg-git             0.10.1-11.4.42.0.0.111.0   ---
developer/versioning/mercurial/hg-git-27          0.10.1-11.4.42.0.0.111.0   ---
developer/versioning/mercurial/hg-git-37          0.10.1-11.4.42.0.0.111.0   ---
legacy/library/python/setuptools-git-34           1.1-11.4.33.0.1.94.0       --o
legacy/library/python/setuptools-git-35           1.1-11.4.33.0.1.94.0       --o
library/python-2/setuptools-git                   1.0-11.4.33.0.1.94.0       --o
library/python-2/setuptools-git-26                1.0-11.4.0.0.1.9.0         --o
library/python-2/setuptools-git-27                1.0-11.4.33.0.1.94.0       --o
library/python/setuptools-git                     1.1-11.4.33.0.1.94.0       --o
library/python/setuptools-git-26                  1.0-11.4.0.0.1.9.0         --o
library/python/setuptools-git-27                  1.1-11.4.33.0.1.94.0       --o
library/python/setuptools-git-34                  1.1-11.4.27.0.1.82.0       --o
library/python/setuptools-git-35                  1.1-11.4.30.0.0.88.0       --o
camden@solaris:~/passenger$ pkg list -a '*gcc*'
NAME (PUBLISHER)                                  VERSION                    IFO
SUNWgcc                                           3.4.3-11.4.0.0.0.14.0      --o
SUNWgccruntime                                    3.4.3-11.4.0.0.0.14.0      --o
developer/gcc                                     11.2.0-11.4.42.0.0.111.0   i--
developer/gcc-10                                  10.3.0-11.4.42.0.0.111.0   ---
developer/gcc-11                                  11.2.0-11.4.42.0.0.111.0   i--
developer/gcc-3                                   3.4.3-11.4.0.0.0.14.0      --o
developer/gcc-4/gcc-c++-47                        4.7.3-11.4.0.0.1.9.0       --o
developer/gcc-4/gcc-c++-48                        4.8.2-11.4.0.0.1.9.0       --o
developer/gcc-4/gcc-c++-49                        4.9.4-11.4.0.0.1.3.0       --o
developer/gcc-4/gcc-c-47                          4.7.3-11.4.0.0.1.9.0       --o
developer/gcc-4/gcc-c-48                          4.8.2-11.4.0.0.1.9.0       --o
developer/gcc-4/gcc-c-49                          4.9.4-11.4.0.0.1.3.0       --o
developer/gcc-4/gcc-common-47                     4.7.3-11.4.0.0.1.9.0       --o
developer/gcc-4/gcc-common-48                     4.8.2-11.4.0.0.1.9.0       --o
developer/gcc-4/gcc-common-49                     4.9.4-11.4.0.0.1.3.0       --o
developer/gcc-4/gcc-gfortran-47                   4.7.3-11.4.0.0.1.9.0       --o
developer/gcc-4/gcc-gfortran-48                   4.8.2-11.4.0.0.1.9.0       --o
developer/gcc-4/gcc-gfortran-49                   4.9.4-11.4.0.0.1.3.0       --o
developer/gcc-4/gcc-gobjc-47                      4.7.3-11.4.0.0.1.9.0       --o
developer/gcc-4/gcc-gobjc-48                      4.8.2-11.4.0.0.1.9.0       --o
developer/gcc-4/gcc-gobjc-49                      4.9.4-11.4.0.0.1.3.0       --o
developer/gcc-45                                  4.5.2-11.4.0.0.1.9.0       --o
developer/gcc-47                                  4.7.3-11.4.0.0.1.9.0       --o
developer/gcc-48                                  4.8.2-11.4.0.0.1.9.0       --o
developer/gcc-49                                  4.9.4-11.4.0.0.1.3.0       --o
developer/gcc-5                                   5.5.0-11.4.27.0.1.82.0     --o
developer/gcc-53                                  5.3.0-11.4.27.0.1.82.0     --o
developer/gcc-7                                   7.5.0-11.4.42.0.0.111.0    ---
developer/gcc-9                                   9.4.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-c                               11.2.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-c++                             11.2.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-c++-10                          10.3.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-c++-11                          11.2.0-11.4.42.0.0.111.0   i--
developer/gcc/gcc-c++-5                           5.5.0-11.4.27.0.1.82.0     --o
developer/gcc/gcc-c++-53                          5.3.0-11.4.27.0.1.82.0     --o
developer/gcc/gcc-c++-7                           7.5.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-c++-9                           9.4.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-c-10                            10.3.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-c-11                            11.2.0-11.4.42.0.0.111.0   i--
developer/gcc/gcc-c-5                             5.5.0-11.4.27.0.1.82.0     --o
developer/gcc/gcc-c-53                            5.3.0-11.4.27.0.1.82.0     --o
developer/gcc/gcc-c-7                             7.5.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-c-9                             9.4.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-common-10                       10.3.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-common-11                       11.2.0-11.4.42.0.0.111.0   i--
developer/gcc/gcc-common-5                        5.5.0-11.4.27.0.1.82.0     --o
developer/gcc/gcc-common-53                       5.3.0-11.4.27.0.1.82.0     --o
developer/gcc/gcc-common-7                        7.5.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-common-9                        9.4.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-gfortran                        11.2.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-gfortran-10                     10.3.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-gfortran-11                     11.2.0-11.4.42.0.0.111.0   i--
developer/gcc/gcc-gfortran-5                      5.5.0-11.4.27.0.1.82.0     --o
developer/gcc/gcc-gfortran-53                     5.3.0-11.4.27.0.1.82.0     --o
developer/gcc/gcc-gfortran-7                      7.5.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-gfortran-9                      9.4.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-gnat                            11.2.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-gnat-11                         11.2.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-go                              11.2.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-go-10                           10.3.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-go-11                           11.2.0-11.4.42.0.0.111.0   i--
developer/gcc/gcc-go-9                            9.4.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-gobjc                           11.2.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-gobjc-10                        10.3.0-11.4.42.0.0.111.0   ---
developer/gcc/gcc-gobjc-11                        11.2.0-11.4.42.0.0.111.0   i--
developer/gcc/gcc-gobjc-5                         5.5.0-11.4.27.0.1.82.0     --o
developer/gcc/gcc-gobjc-53                        5.3.0-11.4.27.0.1.82.0     --o
developer/gcc/gcc-gobjc-7                         7.5.0-11.4.42.0.0.111.0    ---
developer/gcc/gcc-gobjc-9                         9.4.0-11.4.42.0.0.111.0    ---
legacy/developer/gcc-5                            5.5.0-11.4.27.0.1.82.0     --o
legacy/developer/gcc/gcc-c++-5                    5.5.0-11.4.27.0.1.82.0     --o
legacy/developer/gcc/gcc-c-5                      5.5.0-11.4.27.0.1.82.0     --o
legacy/developer/gcc/gcc-common-5                 5.5.0-11.4.27.0.1.82.0     --o
legacy/developer/gcc/gcc-gfortran-5               5.5.0-11.4.27.0.1.82.0     --o
legacy/developer/gcc/gcc-gobjc-5                  5.5.0-11.4.27.0.1.82.0     --o
legacy/system/library/gcc/gcc-c++-runtime-5       5.5.0-11.4.27.0.1.82.0     --o
legacy/system/library/gcc/gcc-c-runtime-5         5.5.0-11.4.27.0.1.82.0     --o
legacy/system/library/gcc/gcc-gfortran-runtime-5  5.5.0-11.4.27.0.1.82.0     --o
legacy/system/library/gcc/gcc-gobjc-runtime-5     5.5.0-11.4.27.0.1.82.0     --o
legacy/system/library/gcc/gcc-runtime-5           5.5.0-11.4.27.0.1.82.0     --o
system/library/gcc-3-runtime                      3.4.3-11.4.0.0.0.14.0      --o
system/library/gcc-45-runtime                     4.5.2-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-c++-runtime                11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-c++-runtime-10             10.3.0-11.4.42.0.0.111.0   ---
system/library/gcc/gcc-c++-runtime-11             11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-c++-runtime-47             4.7.3-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-c++-runtime-48             4.8.2-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-c++-runtime-49             4.9.4-11.4.0.0.1.3.0       --o
system/library/gcc/gcc-c++-runtime-5              5.5.0-11.4.27.0.1.82.0     --o
system/library/gcc/gcc-c++-runtime-53             5.3.0-11.4.27.0.1.82.0     --o
system/library/gcc/gcc-c++-runtime-7              7.5.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-c++-runtime-9              9.4.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-c-runtime                  11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-c-runtime-10               10.3.0-11.4.42.0.0.111.0   ---
system/library/gcc/gcc-c-runtime-11               11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-c-runtime-47               4.7.3-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-c-runtime-48               4.8.2-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-c-runtime-49               4.9.4-11.4.0.0.1.3.0       --o
system/library/gcc/gcc-c-runtime-5                5.5.0-11.4.27.0.1.82.0     --o
system/library/gcc/gcc-c-runtime-53               5.3.0-11.4.27.0.1.82.0     --o
system/library/gcc/gcc-c-runtime-7                7.5.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-c-runtime-9                9.4.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-gfortran-runtime           11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-gfortran-runtime-10        10.3.0-11.4.42.0.0.111.0   ---
system/library/gcc/gcc-gfortran-runtime-11        11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-gfortran-runtime-47        4.7.3-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-gfortran-runtime-48        4.8.2-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-gfortran-runtime-49        4.9.4-11.4.0.0.1.3.0       --o
system/library/gcc/gcc-gfortran-runtime-5         5.5.0-11.4.27.0.1.82.0     --o
system/library/gcc/gcc-gfortran-runtime-53        5.3.0-11.4.27.0.1.82.0     --o
system/library/gcc/gcc-gfortran-runtime-7         7.5.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-gfortran-runtime-9         9.4.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-go-runtime                 9.4.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-go-runtime-10              10.3.0-11.4.42.0.0.111.0   ---
system/library/gcc/gcc-go-runtime-11              11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-go-runtime-9               9.4.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-go-runtime16               10.3.0-11.4.42.0.0.111.0   ---
system/library/gcc/gcc-go-runtime19               11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-gobjc-runtime              11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-gobjc-runtime-10           10.3.0-11.4.42.0.0.111.0   ---
system/library/gcc/gcc-gobjc-runtime-11           11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-gobjc-runtime-47           4.7.3-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-gobjc-runtime-48           4.8.2-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-gobjc-runtime-49           4.9.4-11.4.0.0.1.3.0       --o
system/library/gcc/gcc-gobjc-runtime-5            5.5.0-11.4.27.0.1.82.0     --o
system/library/gcc/gcc-gobjc-runtime-53           5.3.0-11.4.27.0.1.82.0     --o
system/library/gcc/gcc-gobjc-runtime-7            7.5.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-gobjc-runtime-9            9.4.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-runtime                    11.2.0-11.4.42.0.0.111.0   ---
system/library/gcc/gcc-runtime-10                 10.3.0-11.4.42.0.0.111.0   ---
system/library/gcc/gcc-runtime-11                 11.2.0-11.4.42.0.0.111.0   ---
system/library/gcc/gcc-runtime-47                 4.7.3-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-runtime-48                 4.8.2-11.4.0.0.1.9.0       --o
system/library/gcc/gcc-runtime-49                 4.9.4-11.4.0.0.1.3.0       --o
system/library/gcc/gcc-runtime-5                  5.5.0-11.4.27.0.1.82.0     --o
system/library/gcc/gcc-runtime-53                 5.3.0-11.4.27.0.1.82.0     --o
system/library/gcc/gcc-runtime-7                  7.5.0-11.4.42.0.0.111.0    ---
system/library/gcc/gcc-runtime-9                  9.4.0-11.4.42.0.0.111.0    ---
camden@solaris:~/passenger$ pkg list -a '*ruby*'
NAME (PUBLISHER)                                  VERSION                    IFO
SUNWjruby                                         1.1.3-0.169                --o
SUNWruby18                                        1.8.7.174-11.4.0.0.1.9.0   --o
image/graphviz/graphviz-ruby                      2.47.1-11.4.42.0.0.111.0   ---
library/ruby/augeas                               0.5.0-11.4.42.0.0.111.0    ---
library/ruby/concurrent-ruby                      1.1.8-11.4.42.0.0.111.0    ---
library/ruby/deep_merge                           1.2.1-11.4.42.0.0.111.0    ---
library/ruby/ffi                                  1.13.1-11.4.42.0.0.111.0   ---
library/ruby/hiera                                3.4.2-11.4.42.0.0.111.0    ---
library/ruby/hocon                                1.3.1-11.4.42.0.0.111.0    ---
library/ruby/semantic_puppet                      1.0.3-11.4.42.0.0.111.0    ---
library/ruby/stomp                                1.4.4-11.4.42.0.0.111.0    ---
library/ruby/thor                                 1.0.1-11.4.42.0.0.111.0    ---
runtime/java/jruby                                1.1.3-0.169                --o
runtime/ruby                                      2.6-11.4.42.0.0.111.0      i--
runtime/ruby-18                                   1.8.7.374-11.4.0.0.1.9.0   --o
runtime/ruby-19                                   1.9.3.551-11.4.0.0.1.9.0   --o
runtime/ruby-19/ruby-tk                           1.9.3.551-11.4.0.0.1.9.0   --o
runtime/ruby-21                                   2.1.6-11.4.18.0.1.3.0      --o
runtime/ruby-21/ruby-tk                           2.1.6-11.4.18.0.1.3.0      --o
runtime/ruby-23                                   2.3.8-11.4.18.0.1.3.0      --o
runtime/ruby-23/ruby-tk                           2.3.8-11.4.18.0.1.3.0      --o
runtime/ruby-25                                   2.5.9-11.4.39.0.1.107.0    --o
runtime/ruby-26                                   2.6.8-11.4.42.0.0.111.0    i--
CamJN commented 2 years ago

To use passenger-install-apache2-module i had to pass these paths: passenger-install-apache2-module --apxs2-path /usr/apache2/2.4/bin/apxs --apr-config-path /usr/apr/1/bin/amd64/apr-1-config

danowar2k commented 2 years ago

I tried using my original 11.4.0 Vagrant box and updating it to CBE (11.4.42) using

sudo pkg update --accept

This took half an hour, after which I had to reboot Solaris because the changes were only present in the newly created boot environment. I rebooted the VirtualBox VM and tried to connect via SSH, but couldn't anymore. Looking in the VM in VirtualBox, several services couldn't start after the update, including SSH and the service that lets one login locally via VirtualBox. Well, that was a failed experiment.

I'll try to produce a CBE Vagrantbox with Packer tomorrow...I want the reproducible Packer images, anyway.

danowar2k commented 2 years ago

Okay, the CBE Vagrantbox has been created. Just for record, here are my installed packages on that before I do anything with it:

vagrant@dev-solaris:~$ pkg list
NAME (PUBLISHER)                                  VERSION                    IFO
boot/shim                                         0.9-11.4.42.0.0.111.0      i--
compress/bzip2                                    1.0.8-11.4.42.0.0.111.0    i--
compress/gzip                                     1.10-11.4.42.0.0.111.0     i--
compress/p7zip                                    16.2.3-11.4.42.0.0.111.0   i--
compress/pigz                                     2.3.4-11.4.42.0.0.111.0    i--
compress/unzip                                    6.0.3.23-11.4.42.0.0.111.0 i--
compress/xz                                       5.2.3-11.4.42.0.0.111.0    i--
compress/zip                                      3.0-11.4.42.0.0.111.0      i--
consolidation/SunVTS/SunVTS-incorporation         8.2.2-11.4.0.1.0.17.8      i--
consolidation/X/X-incorporation                   11.4-11.4.42.0.0.111.0     i--
consolidation/admin/admin-incorporation           0.5.11-0.175.1.0.0.5.0     i--
consolidation/cde/cde-incorporation               11.4-11.4.42.0.0.111.0     i--
consolidation/dbtg/dbtg-incorporation             0.5.12-5.12.21.0.0.87.0    i--
consolidation/desktop/gnome-incorporation         11.4-11.4.42.0.0.111.0     i--
consolidation/gfx/gfx-incorporation               0.5.11-0.175.1.0.0.5.0     i--
consolidation/ips/ips-incorporation               11.4-11.4.42.0.0.111.0     i--
consolidation/java-7/java-7-incorporation         1.7.0.999.99-0             i--
consolidation/java-8/java-8-incorporation         1.8.0.311.11-0             i--
consolidation/man/man-incorporation               5.12-5.12.21.0.0.101.0     i--
consolidation/nspg/nspg-incorporation             0.5.11-0.175.1.0.0.5.0     i--
consolidation/nvidia/nvidia-incorporation         11.4-11.4.27.0.0.76.0      i--
consolidation/osnet/osnet-incorporation           11.4-11.4.42.0.0.111.1     i--
consolidation/sfw/sfw-incorporation               11.4-11.4.42.0.0.111.0     i--
consolidation/solaris_re/solaris_re-incorporation 11.4-11.4.42.0.0.111.0     i--
consolidation/ssm/ssm-incorporation               2.4.8.0.1-11.4.39.0.0.102.0 i--
consolidation/sunpro/sunpro-incorporation         11.4-11.4.33.0.0.89.0      i--
consolidation/ub_javavm-6/ub_javavm-6-incorporation 1.6.0.999.99-0             i--
consolidation/userland/userland-incorporation     11.4-11.4.42.0.0.111.0     i--
consolidation/xvm/xvm-incorporation               0.5.11-0.175.1.0.0.5.0     i--
crypto/ca-certificates                            11.4-11.4.42.0.0.111.1     i--
crypto/oracle-certificates                        11.4-11.4.42.0.0.111.1     i--
data/shared-mime-info                             1.15-11.4.42.0.0.111.0     i--
database/berkeleydb-5                             5.3.21-11.4.42.0.0.111.0   i--
database/mysql-57/library                         5.7.35-11.4.42.0.0.111.0   i--
database/sqlite-3                                 3.35.5-11.4.42.0.0.111.0   i--
desktop/xdg/desktop-file-utils                    0.23-11.4.42.0.0.111.0     i--
developer/base-developer-utilities                11.4-11.4.42.0.0.111.1     i--
developer/debug/mdb                               11.4-11.4.42.0.0.111.1     i--
developer/macro/cpp                               11.4-11.4.0.1.0.17.0       i--
diagnostic/top                                    3.8-11.4.42.0.0.111.0      i--
driver/crypto/tpm                                 11.4-11.4.42.0.0.111.1     i--
driver/crypto/vtioentropy                         11.4-11.4.42.0.0.111.1     i--
driver/fc/emlxs                                   11.4-11.4.42.0.0.111.1     i--
driver/fc/qlc                                     11.4-11.4.42.0.0.111.1     i--
driver/infiniband/connectx                        11.4-11.4.42.0.0.111.1     i--
driver/management/ipmi                            11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/bge                       11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/bnx                       11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/bnxe                      11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/bnxt                      11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/cxge                      11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/e1000g                    11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/i40e                      11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/igb                       11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/ixgb                      11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/ixgbe                     11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/mlxne                     11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/nge                       11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/ntxn                      11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/nxge                      11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/oce                       11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/qede                      11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/qlcnic                    11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/rge                       11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/sxge                      11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/usbecm                    11.4-11.4.42.0.0.111.1     i--
driver/network/ethernet/vtionet                   11.4-11.4.42.0.0.111.1     i--
driver/parallel/ecpp                              11.4-11.4.42.0.0.111.1     i--
driver/serial/asy                                 11.4-11.4.42.0.0.111.1     i--
driver/serial/usbftdi                             11.4-11.4.42.0.0.111.1     i--
driver/serial/usbsacm                             11.4-11.4.42.0.0.111.1     i--
driver/serial/usbser                              11.4-11.4.42.0.0.111.1     i--
driver/serial/usbser_edge                         11.4-11.4.42.0.0.111.1     i--
driver/serial/usbsksp                             11.4-11.4.42.0.0.111.1     i--
driver/serial/usbsprl                             11.4-11.4.42.0.0.111.1     i--
driver/storage/aac                                11.4-11.4.42.0.0.111.1     i--
driver/storage/ahci                               11.4-11.4.42.0.0.111.1     i--
driver/storage/ata                                11.4-11.4.42.0.0.111.1     i--
driver/storage/blkdev                             11.4-11.4.42.0.0.111.1     i--
driver/storage/cmdk                               11.4-11.4.42.0.0.111.1     i--
driver/storage/cpqary3                            11.4-11.4.42.0.0.111.1     i--
driver/storage/imraid_sas                         11.4-11.4.42.0.0.111.1     i--
driver/storage/lmrc                               11.4-11.4.42.0.0.111.1     i--
driver/storage/lsc                                11.4-11.4.42.0.0.111.1     i--
driver/storage/mega_sas                           11.4-11.4.42.0.0.111.1     i--
driver/storage/mpt                                11.4-11.4.42.0.0.111.1     i--
driver/storage/mpt_sas                            11.4-11.4.42.0.0.111.1     i--
driver/storage/mr_sas                             11.4-11.4.42.0.0.111.1     i--
driver/storage/nvme                               11.4-11.4.42.0.0.111.1     i--
driver/storage/pmcs                               11.4-11.4.42.0.0.111.1     i--
driver/storage/sdcard                             11.4-11.4.42.0.0.111.1     i--
driver/storage/ses                                11.4-11.4.42.0.0.111.1     i--
driver/storage/smp                                11.4-11.4.42.0.0.111.1     i--
driver/storage/vtioblk                            11.4-11.4.42.0.0.111.1     i--
driver/storage/vtioscsi                           11.4-11.4.42.0.0.111.1     i--
driver/x11/xsvc                                   11.4-11.4.42.0.0.111.1     i--
driver/xvm/pv                                     11.4-11.4.42.0.0.111.1     i--
editor/vim/vim-core                               8.2.3582-11.4.42.0.0.111.0 i--
entire                                            11.4-11.4.42.0.0.111.0     i--
file/gnu-coreutils                                8.30-11.4.42.0.0.111.0     i--
group/system/solaris-core-platform                11.4-11.4.42.0.0.111.1     i--
group/system/solaris-minimal-server               11.4-11.4.42.0.0.111.0     i--
image/library/libpng16                            1.6.37-11.4.42.0.0.111.0   i--
install/archive                                   11.4-11.4.42.0.0.111.1     i--
install/distribution-constructor                  11.4-11.4.42.0.0.111.1     i--
library/apr-1                                     1.7.0-11.4.42.0.0.111.0    i--
library/apr-util-1                                1.6.1-11.4.42.0.0.111.0    i--
library/database/gdbm                             1.8.3-11.4.42.0.0.111.0    i--
library/expat                                     2.2.9-11.4.42.0.0.111.0    i--
library/file-monitor/gamin                        0.1.10-11.4.42.0.0.111.0   i--
library/glib2                                     2.66.8-11.4.42.0.0.111.0   i--
library/gmp                                       6.2.1-11.4.42.0.0.111.0    i--
library/gnutls-3                                  3.7.1-11.4.42.0.0.111.0    i--
library/jansson                                   2.10-11.4.42.0.0.111.0     i--
library/json-c                                    0.12-11.4.42.0.0.111.0     i--
library/libedit                                   3.1-11.4.42.0.0.111.0      i--
library/libestr                                   0.1.10-11.4.42.0.0.111.0   i--
library/libevent                                  2.1.12-11.4.42.0.0.111.0   i--
library/libffi                                    3.2.1-11.4.42.0.0.111.0    i--
library/libidn2                                   2.3.0-11.4.42.0.0.111.0    i--
library/libmicrohttpd                             0.9.52-11.4.42.0.0.111.0   i--
library/libmilter                                 8.15.2-11.4.42.0.0.111.0   i--
library/libssh2                                   1.10.0-11.4.42.0.0.111.0   i--
library/libtecla                                  1.6.1-11.4.42.0.0.111.0    i--
library/libxml2                                   2.9.12-11.4.42.0.0.111.0   i--
library/libxslt                                   1.1.33-11.4.42.0.0.111.0   i--
library/mpfr                                      4.1.0-11.4.42.0.0.111.0    i--
library/ncurses                                   6.3-11.4.42.0.0.111.0      i--
library/nghttp2                                   1.41.0-11.4.42.0.0.111.0   i--
library/pcre                                      8.44-11.4.42.0.0.111.0     i--
library/pcre2                                     10.34-11.4.42.0.0.111.0    i--
library/perl-5/sun-solaris                        11.4-11.4.42.0.0.111.0     i--
library/perl-5/sun-solaris-532                    11.4-11.4.42.0.0.111.0     i--
library/popt                                      1.16-11.4.42.0.0.111.0     i--
library/python/asn1crypto-37                      1.3.0-11.4.42.0.0.111.0    i--
library/python/attrs-37                           19.3.0-11.4.42.0.0.111.0   i--
library/python/babel                              2.9.1-11.4.42.0.0.111.0    i--
library/python/babel-37                           2.9.1-11.4.42.0.0.111.0    i--
library/python/cffi                               1.14.0-11.4.42.0.0.111.0   i--
library/python/cffi-37                            1.14.0-11.4.42.0.0.111.0   i--
library/python/chardet-37                         4.0.0-11.4.42.0.0.111.0    i--
library/python/cheroot-37                         6.3.2-11.4.42.0.0.111.0    i--
library/python/cherrypy                           15.0.0-11.4.42.0.0.111.0   i--
library/python/cherrypy-37                        15.0.0-11.4.42.0.0.111.0   i--
library/python/cmd2                               0.9.13-11.4.42.0.0.111.0   i--
library/python/cmd2-37                            0.9.13-11.4.42.0.0.111.0   i--
library/python/colorama-37                        0.4.4-11.4.42.0.0.111.0    i--
library/python/cryptography                       2.5-11.4.42.0.0.111.0      i--
library/python/cryptography-37                    2.5-11.4.42.0.0.111.0      i--
library/python/idna                               2.10-11.4.42.0.0.111.0     i--
library/python/idna-37                            2.10-11.4.42.0.0.111.0     i--
library/python/jsonrpclib                         0.4.2-11.4.42.0.0.111.0    i--
library/python/jsonrpclib-37                      0.4.2-11.4.42.0.0.111.0    i--
library/python/jsonschema                         3.2.0-11.4.42.0.0.111.0    i--
library/python/jsonschema-37                      3.2.0-11.4.42.0.0.111.0    i--
library/python/libxml2-37                         2.9.12-11.4.42.0.0.111.0   i--
library/python/lxml                               4.6.3-11.4.42.0.0.111.0    i--
library/python/lxml-37                            4.6.3-11.4.42.0.0.111.0    i--
library/python/mako                               1.1.5-11.4.42.0.0.111.0    i--
library/python/mako-37                            1.1.5-11.4.42.0.0.111.0    i--
library/python/markupsafe                         2.0.1-11.4.42.0.0.111.0    i--
library/python/markupsafe-37                      2.0.1-11.4.42.0.0.111.0    i--
library/python/more_itertools                     4.2.0-11.4.42.0.0.111.0    i--
library/python/more_itertools-37                  4.2.0-11.4.42.0.0.111.0    i--
library/python/net-snmp-37                        5.8-11.4.42.0.0.111.0      i--
library/python/ply                                3.8-11.4.42.0.0.111.0      i--
library/python/ply-37                             3.8-11.4.42.0.0.111.0      i--
library/python/portend-37                         2.6-11.4.42.0.0.111.0      i--
library/python/prettytable                        1.0.0-11.4.42.0.0.111.0    i--
library/python/prettytable-37                     1.0.0-11.4.42.0.0.111.0    i--
library/python/pybonjour                          1.1.1-11.4.42.0.0.111.0    i--
library/python/pybonjour-37                       1.1.1-11.4.42.0.0.111.0    i--
library/python/pycparser                          2.20-11.4.42.0.0.111.0     i--
library/python/pycparser-37                       2.20-11.4.42.0.0.111.0     i--
library/python/pycurl                             7.43.0.5-11.4.42.0.0.111.0 i--
library/python/pycurl-37                          7.43.0.5-11.4.42.0.0.111.0 i--
library/python/pyopenssl                          19.0.0-11.4.42.0.0.111.0   i--
library/python/pyopenssl-37                       19.0.0-11.4.42.0.0.111.0   i--
library/python/pyperclip-37                       1.8.0-11.4.42.0.0.111.0    i--
library/python/pyrsistent-37                      0.15.7-11.4.42.0.0.111.0   i--
library/python/pytz                               2021.1-11.4.42.0.0.111.0   i--
library/python/pytz-37                            2021.1-11.4.42.0.0.111.0   i--
library/python/rapidjson-37                       1.0-11.4.42.0.0.111.0      i--
library/python/requests                           2.26.0-11.4.42.0.0.111.0   i--
library/python/requests-37                        2.26.0-11.4.42.0.0.111.0   i--
library/python/setuptools                         44.1.1-11.4.42.0.0.111.0   i--
library/python/setuptools-37                      44.1.1-11.4.42.0.0.111.0   i--
library/python/simplejson                         3.17.5-11.4.42.0.0.111.0   i--
library/python/simplejson-37                      3.17.5-11.4.42.0.0.111.0   i--
library/python/six                                1.16.0-11.4.42.0.0.111.0   i--
library/python/six-37                             1.16.0-11.4.42.0.0.111.0   i--
library/python/tempora-37                         1.12-11.4.42.0.0.111.0     i--
library/python/urllib3                            1.26.6-11.4.42.0.0.111.0   i--
library/python/urllib3-37                         1.26.6-11.4.42.0.0.111.0   i--
library/python/wcwidth-37                         0.1.8-11.4.42.0.0.111.0    i--
library/readline                                  8.1-11.4.42.0.0.111.0      i--
library/security/libgpg-error                     1.36-11.4.42.0.0.111.0     i--
library/security/nettle                           3.7.3-11.4.42.0.0.111.0    i--
library/security/openssl                          1.0.2.26-11.4.42.0.0.111.0 i--
library/security/openssl-11                       1.1.1.12-11.4.42.0.0.111.0 i--
library/security/trousers                         0.3.13-11.4.42.0.0.111.0   i--
library/zlib                                      1.2.11-11.4.42.0.0.111.0   i--
mail/mail.local                                   11.4-11.4.42.0.0.111.1     i--
media/cdrtools                                    3.1-11.4.42.0.0.111.0      i--
media/xorriso-core                                1.5.2-11.4.42.0.0.111.0    i--
network/bridging                                  11.4-11.4.42.0.0.111.1     i--
network/dns/bind                                  9.11.36.0.0-11.4.42.0.0.111.0 i--
network/firewall                                  11.4-11.4.42.0.0.111.1     i--
network/firewall/firewall-ftp-proxy               5.5-11.4.42.0.0.111.0      i--
network/firewall/firewall-pflog                   5.5-11.4.42.0.0.111.0      i--
network/open-fabrics                              3.18-11.4.42.0.0.111.0     i--
network/ping                                      11.4-11.4.42.0.0.111.1     i--
network/ssh                                       8.4.0.1-11.4.42.0.0.111.0  i--
network/ssh/ssh-utilities                         11.4-11.4.42.0.0.111.1     i--
package/pkg                                       11.4-11.4.42.0.0.111.0     i--
package/pkg-37                                    11.4-11.4.42.0.0.111.0     i--
package/pkg/system-repository                     11.4-11.4.42.0.0.111.0     i--
package/pkg/zones-proxy                           11.4-11.4.42.0.0.111.0     i--
package/svr4                                      11.4-11.4.42.0.0.111.1     i--
release/name                                      11.4-11.4.42.0.0.111.0     i--
release/notices                                   11.4-11.4.42.0.0.111.0     i--
runtime/perl-532                                  5.32.0-11.4.42.0.0.111.0   i--
runtime/perl-common                               1-11.4.42.0.0.111.0        i--
runtime/python-37                                 3.7.10-11.4.42.0.0.111.0   i--
runtime/tcl-8                                     8.6.7-11.4.42.0.0.111.0    i--
security/kerberos-5                               1.18.4.0-11.4.42.0.0.111.0 i--
security/sudo                                     1.8.31.1-11.4.42.0.0.111.0 i--
service/file-system/smb                           11.4-11.4.42.0.0.111.1     i--
service/network/dns/mdns                          11.4-11.4.42.0.0.111.1     i--
service/network/smtp/sendmail                     8.15.2-11.4.42.0.0.111.0   i--
service/network/ssh                               8.4.0.1-11.4.42.0.0.111.0  i--
service/security/gss                              11.4-11.4.42.0.0.111.1     i--
service/security/kerberos-5                       11.4-11.4.42.0.0.111.1     i--
service/system/sstore                             11.4-11.4.42.0.0.111.1     i--
shell/bash                                        5.1.12-11.4.42.0.0.111.0   i--
shell/ksh93                                       93.21.1.20120801-11.4.42.0.0.111.0 i--
shell/tcsh                                        6.22.0-11.4.42.0.0.111.0   i--
shell/which                                       2.21-11.4.42.0.0.111.0     i--
shell/zsh                                         5.8-11.4.42.0.0.111.0      i--
system/boot-environment-utilities                 11.4-11.4.42.0.0.111.1     i--
system/boot/grub                                  1.99-11.4.42.0.0.111.1     i--
system/boot/wanboot                               11.4-11.4.42.0.0.111.1     i--
system/core-os                                    11.4-11.4.42.0.0.111.1     i--
system/data/hardware-registry                     0.5.11-11.4.42.0.0.111.0   i--
system/data/keyboard/keytables                    11.4-11.4.42.0.0.111.1     i--
system/data/terminfo/terminfo-core                11.4-11.4.42.0.0.111.1     i--
system/data/timezone                              2021.5-11.4                i--
system/device-administration                      11.4-11.4.42.0.0.111.1     i--
system/device-allocation                          11.4-11.4.42.0.0.111.1     i--
system/diagnostic/stackdb                         11.4-11.4.42.0.0.111.1     i--
system/dtrace                                     11.4-11.4.42.0.0.111.1     i--
system/dynamic-reconfiguration                    11.4-11.4.42.0.0.111.1     i--
system/fault-management                           11.4-11.4.42.0.0.111.1     i--
system/fault-management/core-monitor              11.4-11.4.42.0.0.111.1     i--
system/fault-management/fm-snmp-mib               11.4-11.4.42.0.0.111.1     i--
system/fault-management/smtp-notify               11.4-11.4.42.0.0.111.1     i--
system/file-system/autofs                         11.4-11.4.42.0.0.111.1     i--
system/file-system/hsfs                           11.4-11.4.42.0.0.111.1     i--
system/file-system/pcfs                           11.4-11.4.42.0.0.111.1     i--
system/file-system/smb                            11.4-11.4.42.0.0.111.1     i--
system/file-system/ufs                            11.4-11.4.42.0.0.111.1     i--
system/file-system/zfs                            11.4-11.4.42.0.0.111.1     i--
system/firmware-utilities                         11.4-11.4.42.0.0.111.1     i--
system/hal                                        11.4-11.4.42.0.0.111.1     i--
system/install                                    11.4-11.4.42.0.0.111.1     i--
system/install/auto-install/auto-install-common   11.4-11.4.42.0.0.111.1     i--
system/install/configuration                      11.4-11.4.42.0.0.111.1     i--
system/io/fc/fc-port                              11.4-11.4.42.0.0.111.1     i--
system/io/fc/fc-san-management                    11.4-11.4.42.0.0.111.1     i--
system/io/fc/fc-scsi                              11.4-11.4.42.0.0.111.1     i--
system/io/fc/ip-over-fc                           11.4-11.4.42.0.0.111.1     i--
system/io/infiniband                              11.4-11.4.42.0.0.111.1     i--
system/io/infiniband/ethernet-over-ib             11.4-11.4.42.0.0.111.1     i--
system/io/infiniband/ib-device-mgt-agent          11.4-11.4.42.0.0.111.1     i--
system/io/infiniband/ib-sockets-direct            11.4-11.4.42.0.0.111.1     i--
system/io/infiniband/ip-over-ib                   11.4-11.4.42.0.0.111.1     i--
system/io/infiniband/open-fabrics                 11.4-11.4.42.0.0.111.1     i--
system/io/infiniband/reliable-datagram-sockets-v3 11.4-11.4.42.0.0.111.1     i--
system/io/infiniband/rpc-over-rdma                11.4-11.4.42.0.0.111.1     i--
system/io/ultra-wideband                          11.4-11.4.42.0.0.111.1     i--
system/io/usb                                     11.4-11.4.42.0.0.111.1     i--
system/kernel                                     11.4-11.4.42.0.0.111.1     i--
system/kernel/cpu-counters                        11.4-11.4.42.0.0.111.1     i--
system/kernel/crypto                              11.4-11.4.42.0.0.111.1     i--
system/kernel/platform                            11.4-11.4.42.0.0.111.1     i--
system/kernel/rgm                                 11.4-11.4.42.0.0.111.1     i--
system/kernel/suspend-resume                      11.4-11.4.42.0.0.111.1     i--
system/keyboard/keyboard-utilities                11.4-11.4.42.0.0.111.1     i--
system/ksplice                                    11.4-11.4.42.0.0.111.1     i--
system/library                                    11.4-11.4.42.0.0.111.1     i--
system/library/boot-management                    11.4-11.4.42.0.0.111.1     i--
system/library/c++-runtime                        11.4-11.4.33.0.0.89.0      i--
system/library/datalink                           11.4-11.4.42.0.0.111.1     i--
system/library/dbus                               1.10.32-11.4.42.0.0.111.0  i--
system/library/device                             11.4-11.4.42.0.0.111.1     i--
system/library/devid                              11.4-11.4.42.0.0.111.1     i--
system/library/devinfo                            11.4-11.4.42.0.0.111.1     i--
system/library/freetype-2                         2.10.4-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-c++-runtime                11.2.0-11.4.42.0.0.111.0   i--
system/library/gcc/gcc-c-runtime                  11.2.0-11.4.42.0.0.111.0   i--
system/library/hmp-libs                           2.4.8.0.1-11.4.39.0.0.102.0 i--
system/library/iconv/iconv-core                   11.4-11.4.42.0.0.111.1     i--
system/library/install                            11.4-11.4.42.0.0.111.1     i--
system/library/install/libinstzones               11.4-11.4.42.0.0.111.1     i--
system/library/ldap                               11.4-11.4.42.0.0.111.1     i--
system/library/libc                               11.4-11.4.42.0.0.111.1     i--
system/library/libdbus                            1.10.32-11.4.42.0.0.111.0  i--
system/library/libdbus-glib                       0.110-11.4.42.0.0.111.0    i--
system/library/libpcap                            1.9.1-11.4.42.0.0.111.0    i--
system/library/libv12n                            11.4-11.4.42.0.0.111.1     i--
system/library/math                               11.4-11.4.0.1.0.17.0       i--
system/library/pam-core                           11.4-11.4.42.0.0.111.1     i--
system/library/platform                           11.4-11.4.42.0.0.111.1     i--
system/library/policykit                          11.4-11.4.42.0.0.111.1     i--
system/library/processor                          11.4-11.4.42.0.0.111.1     i--
system/library/python/snia-ima-37                 11.4-11.4.42.0.0.111.1     i--
system/library/python/solaris-core                11.4-11.4.42.0.0.111.1     i--
system/library/python/solaris-core-37             11.4-11.4.42.0.0.111.1     i--
system/library/python/sstore                      11.4-11.4.42.0.0.111.1     i--
system/library/python/sstore-37                   11.4-11.4.42.0.0.111.1     i--
system/library/security/crypto                    11.4-11.4.42.0.0.111.1     i--
system/library/security/gss                       11.4-11.4.42.0.0.111.1     i--
system/library/security/libgcrypt                 1.8.8-11.4.42.0.0.111.0    i--
system/library/security/libsasl2                  2.1.26-11.4.42.0.0.111.0   i--
system/library/security/pkcs11                    11.4-11.4.42.0.0.111.1     i--
system/library/security/pkcs11_softtoken          11.4-11.4.42.0.0.111.1     i--
system/library/smf                                11.4-11.4.42.0.0.111.1     i--
system/library/storage/libdiskmgt                 11.4-11.4.42.0.0.111.1     i--
system/library/storage/libfcoe                    11.4-11.4.42.0.0.111.1     i--
system/library/storage/scsi-plugins               11.4-11.4.42.0.0.111.1     i--
system/library/storage/snia-hbaapi                11.4-11.4.42.0.0.111.1     i--
system/library/storage/snia-ima                   11.4-11.4.42.0.0.111.1     i--
system/library/storage/suri                       11.4-11.4.42.0.0.111.1     i--
system/linker                                     11.4-11.4.42.0.0.111.1     i--
system/locale                                     11.4-11.4.42.0.0.111.0     i--
system/locale/extra                               11.4-11.4.42.0.0.111.1     i--
system/locale/nls-administration                  11.4-11.4.42.0.0.111.1     i--
system/management/biosconfig                      2.4.8.0.1-11.4.39.0.0.102.0 i--
system/management/rad                             11.4-11.4.42.0.0.111.1     i--
system/management/rad-37                          11.4-11.4.42.0.0.111.1     i--
system/management/rad/client/rad-c                11.4-11.4.42.0.0.111.1     i--
system/management/rad/client/rad-python-37        11.4-11.4.42.0.0.111.1     i--
system/management/rad/module/rad-archivemgr       11.4-11.4.42.0.0.111.1     i--
system/management/rad/module/rad-bemgr            11.4-11.4.42.0.0.111.1     i--
system/management/rad/module/rad-smf              11.4-11.4.42.0.0.111.1     i--
system/management/rad/module/rad-zfsmgr           11.4-11.4.42.0.0.111.1     i--
system/management/rad/module/rad-zonemgr          11.4-11.4.42.0.0.111.1     i--
system/management/snmp/net-snmp                   5.8-11.4.42.0.0.111.0      i--
system/microcode/amd                              11.4-11.4.42.0.0.111.1     i--
system/microcode/intel                            11.4-11.4.42.0.0.111.1     i--
system/network                                    11.4-11.4.42.0.0.111.1     i--
system/network/bpf                                11.4-11.4.42.0.0.111.1     i--
system/network/ike                                11.4-11.4.42.0.0.111.1     i--
system/network/ldap/openldap                      2.4.57.0.1-11.4.42.0.0.111.0 i--
system/picl                                       11.4-11.4.42.0.0.111.1     i--
system/prerequisite/gnu                           0.5.11-11.4.42.0.0.111.0   i--
system/qemu-img                                   6.0.0-11.4.42.0.0.111.0    i--
system/resource-mgmt/resource-pools               11.4-11.4.42.0.0.111.1     i--
system/rsyslog                                    8.2104.0-11.4.42.0.0.111.0 i--
system/storage/fcoe                               11.4-11.4.42.0.0.111.1     i--
system/storage/fcoe/fcoe-initiator                11.4-11.4.42.0.0.111.1     i--
system/storage/iscsi/iscsi-initiator              11.4-11.4.42.0.0.111.1     i--
system/storage/iscsi/iscsi-iser                   11.4-11.4.42.0.0.111.1     i--
system/storage/media-volume-manager               11.4-11.4.42.0.0.111.1     i--
system/storage/removable-media                    11.4-11.4.42.0.0.111.1     i--
system/system-events                              11.4-11.4.42.0.0.111.1     i--
system/vtio                                       11.4-11.4.42.0.0.111.1     i--
system/xopen/xcu4                                 11.4-11.4.42.0.0.111.1     i--
system/xopen/xcu6                                 11.4-11.4.42.0.0.111.1     i--
system/zones                                      11.4-11.4.42.0.0.111.1     i--
system/zones/brand/brand-solaris                  11.4-11.4.42.0.0.111.1     i--
text/doctools                                     11.4-11.4.42.0.0.111.1     i--
text/gawk                                         5.1.0-11.4.42.0.0.111.0    i--
text/gnu-diffutils                                3.6-11.4.42.0.0.111.0      i--
text/gnu-gettext                                  0.20.1-11.4.42.0.0.111.0   i--
text/groff/groff-core                             1.22.3-11.4.42.0.0.111.0   i--
text/less                                         590-11.4.42.0.0.111.0      i--
text/spelling-utilities                           11.4-11.4.42.0.0.111.1     i--
web/curl                                          7.79.0-11.4.42.0.0.111.0   i--
web/server/apache-24                              2.4.51-11.4.42.0.0.111.0   i--
web/server/apache-24/module/apache-ssl            2.4.51-11.4.42.0.0.111.0   i--
web/server/apache-24/module/apache-wsgi-37        4.7.1-11.4.42.0.0.111.0    i--
web/wget                                          1.20.3-11.4.42.0.0.111.0   i--
danowar2k commented 2 years ago

Oooookay...notes about the CBE version...

Finally, the script...

# From a fresh VM, self-compiling Ruby 2.3.8 etc.
sudo pkg install developer/versioning/git
sudo pkg install gcc-7
sudo pkg install gnu-tar
sudo pkg install pkg:/text/gawk
sudo pkg install gnu-binutils
sudo pkg install developer/build/make
sudo pkg install pkg:/developer/build/gnu-make
sudo pkg install nano

# compile Ruby 2.3.8
wget https://cache.ruby-lang.org/pub/ruby/ruby-2.3.8.tar.gz
gtar -xzvf ruby-2.3.8.tar.gz
cd ruby-2.3.8
# to use GNU awk
export AWK=/usr/bin/gawk
# to build 32 bit
export CC="/usr/bin/gcc -m32"
export CXX="/usr/bin/g++ -m32"
# to use GNU nm
export NM=/usr/bin/gnm
# compile Ruby 2.3.8 32 Bit Solaris binaries
# --enable-shared | Build ruby with shared libraries
# --without-X11 | Build ruby without X11 support (unnecessary on server)
/usr/bin/gmake distclean
bash ./configure --build=i386-pc-solaris2.11 --prefix=/usr/local/ruby/2.3.8 --enable-shared --without-X11
nano ext/openssl/ossl_ssl.c
# Insert "#undef HAVE_SSLV3_METHOD" below '#include "ossl.h"', then save
# compile with parallel jobs
/usr/bin/gmake -j 10 -l 3.5
sudo /usr/bin/gmake install

# Now use that ruby
export PATH=/usr/local/ruby/2.3.8/bin:${PATH}
# Back to home...
cd ~
# Reproduce your steps
git clone https://github.com/phusion/passenger.git
cd passenger/
git submodule init
git submodule update
sudo gem install rake --no-document
# I guess this compiles the apache2 module
rake apache2

This again leads to this error:

n file included from src/agent/Core/SpawningKit/SmartSpawner.h:62:0,
                 from src/agent/Core/SpawningKit/Factory.h:30,
                 from src/agent/Core/ApplicationPool/Context.h:33,
                 from src/agent/Core/ApplicationPool/Common.h:40,
                 from src/agent/Core/ApplicationPool/Pool.h:62,
                 from src/agent/Core/Controller/Request.h:37,
                 from src/agent/Core/Controller/Client.h:32,
                 from src/agent/Core/Controller.h:83,
                 from src/agent/Core/TelemetryCollector.h:45,
                 from src/agent/Core/Config.h:47,
                 from src/agent/Watchdog/Config.h:32,
                 from src/agent/Watchdog/WatchdogMain.cpp:68:
src/agent/Core/SpawningKit/Exceptions.h: In member function ‘Passenger::Json::Value Passenger::SpawningKit::SpawnException::inspectSubprocessDetailsAsJson() const’:
src/agent/Core/SpawningKit/Exceptions.h:1057:34: error: conversion from ‘pid_t {aka long int}’ to ‘Passenger::Json::Value’ is ambiguous
    doc["pid"] = getSubprocessPid();
                                  ^
In file included from src/agent/Watchdog/WatchdogMain.cpp:64:0:
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:877:3: note: candidate: Passenger::Json::Value::Value(bool)
   Value(bool value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:855:3: note: candidate: Passenger::Json::Value::Value(double)
   Value(double value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:853:3: note: candidate: Passenger::Json::Value::Value(Passenger::Json::Value::UInt64)
   Value(UInt64 value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:852:3: note: candidate: Passenger::Json::Value::Value(Passenger::Json::Value::Int64)
   Value(Int64 value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:850:3: note: candidate: Passenger::Json::Value::Value(Passenger::Json::Value::UInt)
   Value(UInt value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:849:3: note: candidate: Passenger::Json::Value::Value(Passenger::Json::Value::Int)
   Value(Int value);
   ^~~~~
src/cxx_supportlib/vendor-modified/jsoncpp/json.h:886:10: note:   initializing argument 1 of ‘Passenger::Json::Value& Passenger::Json::Value::operator=(Passenger::Json::Value&&)’
   Value& operator=(Value&& other) noexcept;
          ^~~~~~~~
In file included from src/agent/Shared/ApiServerUtils.h:68:0,
                 from src/agent/Watchdog/WatchdogMain.cpp:66:
src/cxx_supportlib/DataStructures/LString.h: At global scope:
src/cxx_supportlib/DataStructures/LString.h:83:2: warning: always_inline function might not be inlinable [-Wattributes]
  psg_lstr_last_byte(const LString *str) {
  ^~~~~~~~~~~~~~~~~~
src/cxx_supportlib/DataStructures/LString.h:78:2: warning: always_inline function might not be inlinable [-Wattributes]
  psg_lstr_first_byte(const LString *str) {
  ^~~~~~~~~~~~~~~~~~~
rake aborted!
Command failed with status (1): [/usr/bin/g++ -m32 -o buildout/support-binaries/WatchdogMain.o  -Isrc/agent -Isrc/cxx_supportlib -Isrc/cxx_supportlib/vendor-copy -Isrc/cxx_supportlib/vendor-modified -Isrc/cxx_supportlib/vendor-modified/libev -DUSE_VENDORED_LIBEV -Isrc/cxx_supportlib/vendor-copy/libuv/include -Isrc/cxx_supportlib/vendor-modified/websocketpp -D_REENTRANT -I/usr/local/include -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-long-long -Wno-missing-field-initializers -feliminate-unused-debug-symbols -feliminate-unused-debug-types -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED -DHAS_ALLOCA_H -DHAVE_ACCEPT4 -DHAS_SFENCE -DHAS_LFENCE -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -ggdb -std=gnu++11 -Wno-unused-local-typedefs -Wno-format-nonliteral -DHAS_UNORDERED_MAP -pthreads -D__EXTENSIONS__ -D__SOLARIS__ -D_FILE_OFFSET_BITS=64 -c src/agent/Watchdog/WatchdogMain.cpp]
/export/home/vagrant/passenger/build/support/cplusplus.rb:53:in `run_compiler'
/export/home/vagrant/passenger/build/support/cplusplus.rb:104:in `compile_cxx'
/export/home/vagrant/passenger/build/support/cplusplus.rb:162:in `block in define_cxx_object_compilation_task'
Tasks: TOP => apache2 => buildout/support-binaries/PassengerAgent => buildout/support-binaries/WatchdogMain.o
(See full trace by running task with --trace)
danowar2k commented 2 years ago

Soon I am able to upgrade my application to a more recent version on our old Solaris servers. Soon after that I'll migrate to RedHat. When I'm finished, I'll comment here again. Once we're on RedHat, I don't think this issue will be relevant anymore. I hope you didn't put too much work into it yet...

danowar2k commented 1 year ago

Just out of curiousity I tried to compile the newest sources (https://github.com/phusion/passenger/commit/6cb4c7e58e1a61728c2b866900ef0db485e51a6d), but I've still got the same error.

CamJN commented 1 year ago

Yeah, at this point i believe that it's likely due to the build env you've got, since it works with the compiler and libs from the latest solaris repo. Unfortunately all I can recommend is getting gcc11 and seeing if that helps.

danowar2k commented 1 year ago

Oooh that's something that interests me, I'm gonna change one variable, the gcc compiler...

danowar2k commented 1 year ago

Okay...

I installed gcc 11 and tried to compile Passenger again, same error. I recompiled ruby 2.3.8 32-Bit with gcc 11 and then recompiled Passenger, same error.

THEN I decided "to hell with it" and compiled Passenger 64 Bits, even with Ruby still being 32 bit.

And...that worked. So the problem can be limited to when compiling the 32 bit binaries.

danowar2k commented 1 year ago

I think we can call this "won't fix", because I'm already on Ruby 2.6.10. Next week I think I'm gonna be ready to migrate away from Solaris, so...

danowar2k commented 1 year ago

Yep, this can be closed (I just don't do it because I don't know if anyone else is involved...)