Bug 1417747

Summary: Unable to compile on Mac
Product: OKD Reporter: Troy Dawson <tdawson>
Component: NetworkingAssignee: Ben Bennett <bbennett>
Status: CLOSED CURRENTRELEASE QA Contact: Meng Bo <bmeng>
Severity: high Docs Contact:
Priority: unspecified    
Version: 3.xCC: aos-bugs, eparis, xtian
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-05-30 12:47:50 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Troy Dawson 2017-01-30 21:10:24 UTC
Description of problem:
Unable to build Origin on Mac's, using the cross compile scripts

Version-Release number of selected component (if applicable):
v1.5.0-alpha.2
latest in git log is fe1f9cc2f435e3bea326b7841126a362629bfb42

How reproducible:
100%

Steps to Reproduce:
1. git clone git@github.com:openshift/origin.git
2. cd origin
3. tito build --test --srpm
4. Try to build that src.rpm, for example 
    mock -r rhaos-3.5-rhel-7 --rebuild /tmp/tito/origin-0.0.1-0.git.16268.fe1f9cc.el7.src.rpm

Actual results:
+ cd /builddir/build/BUILD
+ cd origin-git-16268.fe1f9cc
+ OS_GIT_TREE_STATE=clean
+ OS_GIT_VERSION=v1.5.0-alpha.2+fe1f9cc-271
+ OS_GIT_COMMIT=fe1f9cc
+ OS_GIT_MAJOR=1
+ OS_GIT_MINOR=5+
+ hack/build-cross.sh
++ Building go targets for linux/amd64: images/pod cmd/dockerregistry cmd/gitserver pkg/sdn/plugin/sdn-cni-plugin vendor/github.com/containernetworking/cni/plugins/ipam/host-local vendor/github.com/containernetworking/cni/plugins/main/loopback examples/hello-openshift examples/deployment
++ Building go targets for linux/amd64: cmd/openshift cmd/oc
++ Building go targets for darwin/amd64: cmd/openshift cmd/oc
# github.com/openshift/origin/pkg/sdn/plugin
pkg/sdn/plugin/pod.go:62: cannot use pm (type *podManager) as type podHandler in assignment:
        *podManager does not implement podHandler (wrong type for update method)
                have update(*cniserver.PodRequest) (*runningPod, error)
                want update(*cniserver.PodRequest) (uint32, error)
[ERROR] PID 16264: hack/common.sh:147: `local -a binaries=("$@")` exited with status 1.
[INFO]          Stack Trace: 
[INFO]            1: hack/common.sh:147: `local -a binaries=("$@")`
[INFO]            2: hack/build-cross.sh:71: os::build::build_binaries
[INFO]   Exiting with code 1.



Expected results:
+ cd /builddir/build/BUILD
+ cd atomic-openshift-git-0.e377fa2
+ OS_GIT_TREE_STATE=clean
+ OS_GIT_VERSION=v3.5.0.10+e377fa2
+ OS_GIT_COMMIT=e377fa2
+ OS_GIT_MAJOR=3
+ OS_GIT_MINOR=5+
+ hack/build-cross.sh
++ Building go targets for linux/amd64: images/pod cmd/dockerregistry cmd/gitserver pkg/sdn/plugin/sdn-cni-plugin vendor/github.com/containernetworking/cni/plugins/ipam/host-local vendor/github.com/containernetworking/cni/plugins/main/loopback examples/hello-openshift examples/deployment
++ Building go targets for linux/amd64: cmd/openshift cmd/oc
++ Building go targets for darwin/amd64: cmd/openshift cmd/oc
++ Building go targets for windows/amd64: cmd/openshift cmd/oc
++ Building go targets for linux/386: cmd/openshift cmd/oc
++ Building go targets for linux/amd64: test/extended/extended.test


Additional info:
The expected results come from a atomic-openshift build, but that's where we found the bug, tacking it back to origin.

Comment 2 openshift-github-bot 2017-01-31 06:10:29 UTC
Commit pushed to master at https://github.com/openshift/origin

https://github.com/openshift/origin/commit/b9dcb9f8da6477719f0b9b825f3ffa66b9a7e1bf
Fix stub interface so Mac compilations work

The stub "unsupported" interface had the wrong signature.  This
corrects it to prevent a compilation error on Macs.

Fixes bug 1417747 https://bugzilla.redhat.com/show_bug.cgi?id=1417747

Comment 3 Troy Dawson 2017-01-31 13:46:31 UTC
I have verified on my machine that this works.

Comment 4 Meng Bo 2017-02-13 07:00:42 UTC
Compile succeeded on Mac OSX 10.12 with latest origin code.

Verify the bug.