Skip to content

Commit

Permalink
#158 change g2 to er
Browse files Browse the repository at this point in the history
  • Loading branch information
docktermj committed Aug 16, 2024
1 parent 291ef71 commit e093d91
Show file tree
Hide file tree
Showing 9 changed files with 26 additions and 26 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/go-test-darwin.yaml.disabled
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ name: Go test darwin
on: [pull_request, workflow_dispatch]

env:
DYLD_LIBRARY_PATH: /opt/senzing/g2/lib:/opt/senzing/g2/lib/macos
LD_LIBRARY_PATH: /opt/senzing/g2/lib:/opt/senzing/g2/lib/macos
DYLD_LIBRARY_PATH: /opt/senzing/er/lib:/opt/senzing/er/lib/macos
LD_LIBRARY_PATH: /opt/senzing/er/lib:/opt/senzing/er/lib/macos
SENZING_LOG_LEVEL: TRACE
SENZING_TOOLS_DATABASE_URL: sqlite3://na:na@nowhere/tmp/sqlite/G2C.db

Expand Down Expand Up @@ -43,7 +43,7 @@ jobs:
senzingapi-version: ${{ matrix.senzingapi-version }}

- name: Copy /etc files
run: sudo mkdir -p /opt/senzing/g2/etc && sudo cp testdata/senzing-license/g2.lic /opt/senzing/g2/etc/g2.lic
run: sudo mkdir -p /opt/senzing/er/etc && sudo cp testdata/senzing-license/g2.lic /opt/senzing/er/etc/g2.lic

- name: Copy test database files
run: mkdir -p /tmp/sqlite && cp testdata/sqlite/G2C.db /tmp/sqlite/
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/go-test-linux.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Go test linux
on: [push]

env:
LD_LIBRARY_PATH: /opt/senzing/g2/lib
LD_LIBRARY_PATH: /opt/senzing/er/lib
SENZING_LOG_LEVEL: TRACE
SENZING_TOOLS_DATABASE_URL: sqlite3://na:na@nowhere/tmp/sqlite/G2C.db

Expand Down
20 changes: 10 additions & 10 deletions .github/workflows/golangci-lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,20 +31,20 @@ jobs:
- name: Copy Senzing headers
run: |
mkdir --parents ./szconfig/gohelpers
cp /opt/senzing/g2/sdk/c/*.h ./szconfig/
cp /opt/senzing/g2/sdk/c/gohelpers/*.h ./szconfig/gohelpers
cp /opt/senzing/er/sdk/c/*.h ./szconfig/
cp /opt/senzing/er/sdk/c/gohelpers/*.h ./szconfig/gohelpers
mkdir --parents ./szconfigmanager/gohelpers
cp /opt/senzing/g2/sdk/c/*.h ./szconfigmanager/
cp /opt/senzing/g2/sdk/c/gohelpers/*.h ./szconfigmanager/gohelpers
cp /opt/senzing/er/sdk/c/*.h ./szconfigmanager/
cp /opt/senzing/er/sdk/c/gohelpers/*.h ./szconfigmanager/gohelpers
mkdir --parents ./szdiagnostic/gohelpers
cp /opt/senzing/g2/sdk/c/*.h ./szdiagnostic/
cp /opt/senzing/g2/sdk/c/gohelpers/*.h ./szdiagnostic/gohelpers
cp /opt/senzing/er/sdk/c/*.h ./szdiagnostic/
cp /opt/senzing/er/sdk/c/gohelpers/*.h ./szdiagnostic/gohelpers
mkdir --parents ./szengine/gohelpers
cp /opt/senzing/g2/sdk/c/*.h ./szengine/
cp /opt/senzing/g2/sdk/c/gohelpers/*.h ./szengine/gohelpers
cp /opt/senzing/er/sdk/c/*.h ./szengine/
cp /opt/senzing/er/sdk/c/gohelpers/*.h ./szengine/gohelpers
mkdir --parents ./szproduct/gohelpers
cp /opt/senzing/g2/sdk/c/*.h ./szproduct/
cp /opt/senzing/g2/sdk/c/gohelpers/*.h ./szproduct/gohelpers
cp /opt/senzing/er/sdk/c/*.h ./szproduct/
cp /opt/senzing/er/sdk/c/gohelpers/*.h ./szproduct/gohelpers
- name: Setup go
uses: actions/setup-go@v5
Expand Down
8 changes: 4 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ COPY . ${GOPATH}/src/template-go

# Copy files from prior stage.

COPY --from=senzingapi_runtime "/opt/senzing/g2/lib/" "/opt/senzing/g2/lib/"
COPY --from=senzingapi_runtime "/opt/senzing/g2/sdk/c/" "/opt/senzing/g2/sdk/c/"
COPY --from=senzingapi_runtime "/opt/senzing/er/lib/" "/opt/senzing/er/lib/"
COPY --from=senzingapi_runtime "/opt/senzing/er/sdk/c/" "/opt/senzing/er/sdk/c/"

# Set path to Senzing libs.

ENV LD_LIBRARY_PATH=/opt/senzing/g2/lib/
ENV LD_LIBRARY_PATH=/opt/senzing/er/lib/

# Build go program.

Expand Down Expand Up @@ -77,7 +77,7 @@ USER 1001

# Runtime environment variables.

ENV LD_LIBRARY_PATH=/opt/senzing/g2/lib/
ENV LD_LIBRARY_PATH=/opt/senzing/er/lib/

# Runtime execution.

Expand Down
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ GO_ARCH = $(word 2, $(GO_OSARCH))

# Conditional assignment. ('?=')
# Can be overridden with "export"
# Example: "export LD_LIBRARY_PATH=/path/to/my/senzing/g2/lib"
# Example: "export LD_LIBRARY_PATH=/path/to/my/senzing/er/lib"

DOCKER_IMAGE_TAG ?= $(GIT_REPOSITORY_NAME):$(GIT_VERSION)
GOBIN ?= $(shell go env GOPATH)/bin
LD_LIBRARY_PATH ?= /opt/senzing/g2/lib
LD_LIBRARY_PATH ?= /opt/senzing/er/lib

# Export environment variables.

Expand Down
2 changes: 1 addition & 1 deletion bin/macos_exec_dyld.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/zsh

export DYLD_LIBRARY_PATH=/opt/senzing/g2/lib:/opt/senzing/g2/lib/macos
export DYLD_LIBRARY_PATH=/opt/senzing/er/lib:/opt/senzing/er/lib/macos
export LD_LIBRARY_PATH=${DYLD_LIBRARY_PATH}

"$@"
4 changes: 2 additions & 2 deletions docs/development.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ These are "one-time tasks" which may already have been completed.
Since the Senzing library is a prerequisite, it must be installed first.

1. Verify Senzing C shared objects, configuration, and SDK header files are installed.
1. `/opt/senzing/g2/lib`
1. `/opt/senzing/g2/sdk/c`
1. `/opt/senzing/er/lib`
1. `/opt/senzing/er/sdk/c`
1. `/etc/opt/senzing`

1. If not installed, see [How to Install Senzing for Go Development].
Expand Down
2 changes: 1 addition & 1 deletion makefiles/linux.mk
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# Variables
# -----------------------------------------------------------------------------

LD_LIBRARY_PATH ?= /opt/senzing/g2/lib
LD_LIBRARY_PATH ?= /opt/senzing/er/lib
SENZING_TOOLS_DATABASE_URL ?= sqlite3://na:na@nowhere/tmp/sqlite/G2C.db
PATH := $(MAKEFILE_DIRECTORY)/bin:/$(HOME)/go/bin:$(PATH)

Expand Down
4 changes: 2 additions & 2 deletions package.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ COPY . ${GOPATH}/src/${GO_PACKAGE_NAME}

# Copy files from prior stage.

COPY --from=senzingapi_runtime "/opt/senzing/g2/lib/" "/opt/senzing/g2/lib/"
COPY --from=senzingapi_runtime "/opt/senzing/g2/sdk/c/" "/opt/senzing/g2/sdk/c/"
COPY --from=senzingapi_runtime "/opt/senzing/er/lib/" "/opt/senzing/er/lib/"
COPY --from=senzingapi_runtime "/opt/senzing/er/sdk/c/" "/opt/senzing/er/sdk/c/"

# Build go program.

Expand Down

0 comments on commit e093d91

Please sign in to comment.