<p>Issue related to <a href="https://github.com/kamailio/kamailio/blob/master/pkg/kamailio/obs/kamailio.spec#L979"><code>share_prefix=%{_prefix}</code></a> options of <code>make cfg</code><br>
When this options is not used then <code>make install</code> command is executed properly but later packaging is failed by <code>rpath</code> check error.</p>
<pre><code>+ /usr/lib/rpm/check-buildroot
Binary file /home/build/rpmbuild/BUILDROOT/kamailio-5.2.0-0.el7.centos.x86_64/usr/lib64/kamailio/modules/db_redis.so matches
Found '/home/build/rpmbuild/BUILDROOT/kamailio-5.2.0-0.el7.centos.x86_64' in installed files; aborting
error: Bad exit status from /var/tmp/rpm-tmp.BKXKDY (%install)


RPM build errors:
    Bad exit status from /var/tmp/rpm-tmp.BKXKDY (%install)
[build@node0 SPECS]$ 
</code></pre>
<p>As options we can disable build of <code>db_redis</code> and delete <code>share_prefix=%{_prefix}</code> options of <code>make cfg</code></p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/kamailio/kamailio/issues/1709#issuecomment-436276398">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AF36ZVl3FhMDDTZ-cAaUSYJIfPObnOo_ks5usaAXgaJpZM4YQjTO">mute the thread</a>.<img src="https://github.com/notifications/beacon/AF36ZfrluPmuB7Czhs5RdEtE4bGj0p6Iks5usaAXgaJpZM4YQjTO.gif" height="1" width="1" alt="" /></p>
<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/kamailio/kamailio","title":"kamailio/kamailio","subtitle":"GitHub repository","main_image_url":"https://assets-cdn.github.com/images/email/message_cards/header.png","avatar_image_url":"https://assets-cdn.github.com/images/email/message_cards/avatar.png","action":{"name":"Open in GitHub","url":"https://github.com/kamailio/kamailio"}},"updates":{"snippets":[{"icon":"PERSON","message":"@sergey-safarov in #1709: Issue related to [`share_prefix=%{_prefix}`](https://github.com/kamailio/kamailio/blob/master/pkg/kamailio/obs/kamailio.spec#L979) options of `make cfg`\r\nWhen this options is not used then `make install` command is executed properly but later packaging is failed by `rpath` check error.\r\n```\r\n+ /usr/lib/rpm/check-buildroot\r\nBinary file /home/build/rpmbuild/BUILDROOT/kamailio-5.2.0-0.el7.centos.x86_64/usr/lib64/kamailio/modules/db_redis.so matches\r\nFound '/home/build/rpmbuild/BUILDROOT/kamailio-5.2.0-0.el7.centos.x86_64' in installed files; aborting\r\nerror: Bad exit status from /var/tmp/rpm-tmp.BKXKDY (%install)\r\n\r\n\r\nRPM build errors:\r\n    Bad exit status from /var/tmp/rpm-tmp.BKXKDY (%install)\r\n[build@node0 SPECS]$ \r\n```\r\nAs options we can disable build of `db_redis` and delete `share_prefix=%{_prefix}` options of `make cfg`"}],"action":{"name":"View Issue","url":"https://github.com/kamailio/kamailio/issues/1709#issuecomment-436276398"}}}</script>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/kamailio/kamailio/issues/1709#issuecomment-436276398",
"url": "https://github.com/kamailio/kamailio/issues/1709#issuecomment-436276398",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
},
{
"@type": "MessageCard",
"@context": "http://schema.org/extensions",
"hideOriginalBody": "false",
"originator": "AF6C5A86-E920-430C-9C59-A73278B5EFEB",
"title": "Re: [kamailio/kamailio] Cannot be packaged into RPM master and 5.2 branch (#1709)",
"sections": [
{
"text": "",
"activityTitle": "**sergey-safarov**",
"activityImage": "https://assets-cdn.github.com/images/email/message_cards/avatar.png",
"activitySubtitle": "@sergey-safarov",
"facts": [

]
}
],
"potentialAction": [
{
"name": "Add a comment",
"@type": "ActionCard",
"inputs": [
{
"isMultiLine": true,
"@type": "TextInput",
"id": "IssueComment",
"isRequired": false
}
],
"actions": [
{
"name": "Comment",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"IssueComment\",\n\"repositoryFullName\": \"kamailio/kamailio\",\n\"issueId\": 1709,\n\"IssueComment\": \"{{IssueComment.value}}\"\n}"
}
]
},
{
"name": "Close issue",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"IssueClose\",\n\"repositoryFullName\": \"kamailio/kamailio\",\n\"issueId\": 1709\n}"
},
{
"targets": [
{
"os": "default",
"uri": "https://github.com/kamailio/kamailio/issues/1709#issuecomment-436276398"
}
],
"@type": "OpenUri",
"name": "View on GitHub"
},
{
"name": "Unsubscribe",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"MuteNotification\",\n\"threadId\": 406992078\n}"
}
],
"themeColor": "26292E"
}
]</script>