Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

install failure #1

Closed
vielmetti opened this issue May 30, 2023 · 4 comments
Closed

install failure #1

vielmetti opened this issue May 30, 2023 · 4 comments

Comments

@vielmetti
Copy link

Last 15 lines from /Users/emv/Library/Logs/Homebrew/netperf-enable-demo/02.make:
    ^
2 errors generated.
make[2]: *** [net_uuid.o] Error 1
make[2]: *** Waiting for unfinished jobs....
netcpu_osx.c:73:3: error: call to undeclared function 'mach_port_deallocate'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
  mach_port_deallocate(lib_host_port);
  ^
netcpu_osx.c:73:3: note: did you mean 'mach_voucher_deallocate'?
/Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk/usr/include/mach/message.h:919:33: note: 'mach_voucher_deallocate' declared here
extern kern_return_t            mach_voucher_deallocate(
                                ^
1 error generated.
make[2]: *** [netcpu_osx.o] Error 1
make[1]: *** [install-recursive] Error 1
make: *** [install-recursive] Error 1

If reporting this issue please do so at (not Homebrew/brew or Homebrew/homebrew-core):
  https://github.com/kris-anderson/homebrew-netperf/issues

The system is a MacBook Air M1, running Ventura 13.4. Happy to provide additional info as needed or to test code.

@kris-anderson
Copy link
Owner

kris-anderson commented Jul 14, 2023

Thank you for reporting this.

I was able to verify the same issue on the latest macOS 13.4.1 on both an intel and arm device.

Turns out, this is actually an issue with the default homebrew version as well. Homebrew is building the bottles (pre-built) and installing that. As long as they're not being built on the latest macOS, they appear to still build. However, if you try to build it yourself and not use a bottle, you'll get the same error. For example:

brew install --build-from-source netperf

I played around with this tonight and figured out a way to get this working. The netperf-2.7.0.tar.gz provided by HP is some 40 commits behind the master branch and was created in 2015:
HewlettPackard/netperf#75

I git cloned the latest from HP's repo, created my own tar.gz file, and stuck that up on my S3 bucket. I didn't change anything in there as I wanted it to be 1:1, I just wanted to get the latest copy of everything from that repo.

I then updated my homebrew formula here to grab the new file from my S3 bucket. In addition to that, I also ran into a build issue on macOS where there's an open PR on the HP side of things that hadn't been merged, so I include that as well. Here's the open PR on HP's end:
HewlettPackard/netperf#67

With both the latest files from HP and that extra PR that hadn't been merged, I am able to brew install kris-anderson/netperf/netperf-enable-demo.

Would you mind updating the the latest version and see if it's working again for you?

@vielmetti
Copy link
Author

Thanks @kris-anderson - here's the current output which gets stuck on compile.

> brew install kris-anderson/netperf/netperf-enable-demo
==> Fetching kris-anderson/netperf/netperf-enable-demo
==> Downloading https://kris-anderson.s3.us-west-2.amazonaws.com/homebrew-netperf/netperf-2.7.0.1.tar.gz
Already downloaded: /Users/emv/Library/Caches/Homebrew/downloads/fb7a5605ee467ed9721fd2dbf50834925bb0557d5aeb24cc017059db8fcb6a95--netperf-2.7.0.1.tar.gz
==> Installing netperf-enable-demo from kris-anderson/netperf
==> ./configure --enable-demo --prefix=/opt/homebrew/Cellar/netperf-enable-demo/2.7.0.1
Last 15 lines from /Users/emv/Library/Logs/Homebrew/netperf-enable-demo/01.configure:
2023-07-14 12:35:41 +0000

./configure
--disable-dependency-tracking
--enable-demo
--prefix=/opt/homebrew/Cellar/netperf-enable-demo/2.7.0.1

configure: error: cannot find required auxiliary files: compile

If reporting this issue please do so at (not Homebrew/brew or Homebrew/homebrew-core):
  https://github.com/kris-anderson/homebrew-netperf/issues

@kris-anderson
Copy link
Owner

@vielmetti thank you again for the feedback.

I was also able to reproduce that on my M1. I previously only tested on my intel device.

And thank for for the PR. That got me thinking some more, and I made a few other changes to this that I'd like to get your thoughts on.

I added the following:

depends_on "automake"
system "./autogen.sh"

I believe this is similar to what your PR does. Previously, on my intel, I ran the autogen.sh script and then built the gzip file, because that autogen.sh script generates the cofiguration file that is called during the build process. But I realized that my gizp file then only worked on my intel device.

Instead, I now did a git clone of HP's repo, and create an exact copy of that repo as my gzip file. Then, I updated this build process to call that autogen.sh file as part of the build process.

Can you try the latest changes I just pushed and see if this is working for you?

Alternatively, you don't even need to use my gzip file to install this. You can install directly from HP's main source branch if you'd like with the following command:

brew install --HEAD kris-anderson/netperf/netperf-enable-demo

@vielmetti
Copy link
Author

Thanks @kris-anderson ! I did the brew install --HEAD kris-anderson/netperf/netperf-enable-demo step and the install went to completion without troubles.

My next step is to get flent all up and working, and this was a dependency for that, so progress!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants