| |
@@ -86,7 +86,9 @@
|
| |
|
| |
TOP_DIR=$(pwd)
|
| |
# Use testing port because the standard mysqld port 3306 is occupied.
|
| |
- MYSQL_TEST_PORT="13306"
|
| |
+ # Assign a random port to consider a case of multi builds in parallel in a host.
|
| |
+ # https://src.fedoraproject.org/rpms/rubygem-pg/pull-request/3
|
| |
+ MYSQL_TEST_PORT="$((13306 + ${RANDOM} % 1000))"
|
| |
MYSQL_TEST_USER=$(id -un)
|
| |
MYSQL_TEST_DATA_DIR="${TOP_DIR}/data"
|
| |
MYSQL_TEST_SOCKET="${TOP_DIR}/mysql.sock"
|
| |
The build failure due to the fixed testing port in %check section happens for rubygem-mysql2 in RHEL build system.
That is same situation with rubygem-pg.
I like fixing this as well as rubygem-pg.
https://src.fedoraproject.org/rpms/rubygem-pg/blob/master/f/rubygem-pg.spec#_85
I add below rubygem-pg's URL as a reference to both comment line and commit message.
https://github.com/ged/ruby-pg/pull/39
I checked different port is assigned for each other.
Testing on mock envrionment: ok
Rpmlint: not okay. But I prefer to fix it on another PR.