Foo Bar
Foo Bar

Reputation: 11

rpm build for different os.version

I would like for a RHEL6 build machine to construct a RHEL5 compatible rpm using the maven rpm build plugin. I see how to modify the arch (amd64 vs i386) and os.name (linux vs. ...) but not RHEL5 vs. RHEL5.

Upvotes: 1

Views: 2182

Answers (1)

Jeff Johnson
Jeff Johnson

Reputation: 2390

Your best bet is to create a chroot (or perhaps run a VM or docker image, or use mock) that contains RHEL5 on the RHEL6 host, and use that for building packages.

There are specific ways to configure rpm to use ZLIB rather than XZ, and use MD5 rather than SHA256, as well as to change labeling of RHEL6 vs RHEL5.

There is no one magic switch to achieve building RHEL5 on RHEL6 (without using mock etc isolation) because RHEL5 and RHEL6 are distinct operating systems with different API's and versions which will block success for all but trivial packages.

Upvotes: 1

Related Questions