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

[Bug]: build instructions build against bundled solclient 7.8, the latest C API is 7.30 #45

Open
solace-brendabutler opened this issue Aug 8, 2024 · 6 comments
Assignees
Labels

Comments

@solace-brendabutler
Copy link

Bug Description

Build instructions do not say how to update the API in solace-samples-c to the latest. The instructions will have the user build against the bundled CCSMP 7.8. Current version as of today is 7.30

Also the "tutorials" links under Contents ("tutorials home page") and under Running the Samples ("tutorials") are broken.

Expected Behavior

I expect to see instructions before the build (step 3) that say "put the API header files and the lib files , adjust the makefiles/env variables so the desired API is built/linked against".

Steps to Reproduce

Read the top-level README.md, the setenv.sh (build/intro/linux/x64/setenv.sh) and the Makefile (build/intro/linux/x64/Makefile). Also note the bundled version of the API here: lib/linux/x64/libsolclient_d.so.1.7.8.0.11

Solace Product

Solace APIs

Solace Broker version

No response

Solace API

C

Solace API version

7.30

@solace-brendabutler
Copy link
Author

Here's a diff for the Makefile to show what I mean. It requires an extra environment variable that points to the top level of the unpacked CCSMP API. It has been tested against CCSMP 7.30.0.2, but probably doesn't work with the bundled CCSMP 7.8.

[user@host build]$ git diff
diff --git a/build/intro/linux/x64/Makefile b/build/intro/linux/x64/Makefile
index 616b408..936e670 100644
--- a/build/intro/linux/x64/Makefile
+++ b/build/intro/linux/x64/Makefile
@@ -7,16 +7,21 @@ CXX:=gcc -g
 ifeq ($(CCSMPHOME),)
        CCSMPHOME:=../../../..
 endif
+ifeq ($(CCSMPAPIHOME),)
+$(error Need to set CCSMPAPIHOME to point to where the API is)
+endif

-INCDIRS:=-I$(CCSMPHOME) \
-        -I$(CCSMPHOME)/inc \
-        -I.
+#INCDIRS:=-I$(CCSMPHOME) \
+#       -I$(CCSMPHOME)/inc \
+#       -I.
+INCDIRS:=-I. -I$(CCSMPAPIHOME)/include

 SIXTY_FOUR_COMPAT:=
 OS:=linux
 ARCH:=x64
-LINUXLIBDIR=$(CCSMPHOME)/lib/$(OS)/$(ARCH)
-LIBDIRS:=-L$(CCSMPHOME)/lib -L$(LINUXLIBDIR)
+#LINUXLIBDIR=$(CCSMPAPIHOME)/lib/$(OS)/$(ARCH)
+#LIBDIRS:=-L$(CCSMPAPIHOME)/lib  # -L$(LINUXLIBDIR)
+LIBDIRS:=-L$(CCSMPAPIHOME)/lib
 LLSYS:=$(SIXTY_FOUR_COMPAT)
 VPATH:=$(CCSMPHOME)/src/intro
 OUTPUTDIR:=$(CCSMPHOME)/bin
[user@host build]$

@Mrc0113
Copy link
Member

Mrc0113 commented Aug 9, 2024

I believe #44 addresses the old version of the API.
Keeping this open to address:

Also the "tutorials" links under Contents ("tutorials home page") and under Running the Samples ("tutorials") are broken.

@solace-brendabutler
Copy link
Author

The issue is not so much that the bundled API is old, as it is that the instructions to use another version of the API are incomplete/wrong.
It's OK to have a bundled API and have the build work for it - but we also need to be able to switch that out and use a current API.
The new API must be referenced at compile time as well as run time. The instructions in the readme only reference the new API at run time. The diff I have provided does that for CCSMP 7.30. But it should be adjusted to work for both the old API and any new one.

@solace-brendabutler
Copy link
Author

"But it should be adjusted to work for both the old API and any new one." and for Mac architecture.

@aaron-613
Copy link
Contributor

Hi @solace-brendabutler , how are you? The bundled libs and projects have now been updated. Please could you pull the latest and test again to see if the current addresses your issue? Then we can close this. Thanks!

@aaron-613
Copy link
Contributor

Fixed in #44

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

No branches or pull requests

3 participants