Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
# _/Users/larz/Programming/random
duplicate symbol __Z3addii in:
ld: 1 duplicate symbol for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
/usr/local/go/pkg/tool/darwin_amd64/6l: running clang failed: unsuccessful exit status 0x100
#include "main.hh"
int add(int first, int second) {
return first + second;
package main
import "C"
func main() {
println(Add(1, 2))
#ifndef H_MAIN
#define H_MAIN 1
int add(int, int);
%module main
#include "main.hh"
%include "main.hh"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment