質問編集履歴
3
CFLAGS = -DU_DISABLE_RENAMING=1 に修正後について補足
test
CHANGED
File without changes
|
test
CHANGED
@@ -75,6 +75,8 @@
|
|
75
75
|
|
76
76
|
```
|
77
77
|
|
78
|
+
---
|
79
|
+
|
78
80
|
だったのですがアドバイスの通りやってみたのですが、(pacmanの実行とmakefileの修正)
|
79
81
|
|
80
82
|
```makefile
|
@@ -109,3 +111,22 @@
|
|
109
111
|
collect2.exe: error: ld returned 1 exit status
|
110
112
|
make: *** [C:/CPP/_.mk:9: test.exe] Error 1
|
111
113
|
```
|
114
|
+
---
|
115
|
+
このあと、アドバイス(CFLAGS = -DU_DISABLE_RENAMING=1)通りに変更するとこのようなエラーになりました
|
116
|
+
```
|
117
|
+
c:/msys64/mingw64/bin/g++ -DU_DISABLE_RENAMING=1 -fexec-charset=cp932 -c test.cpp
|
118
|
+
c:/msys64/mingw64/bin/g++ -o test.exe test.o -Lc:/msys64/mingw64/lib -licudt -licuin -licuio -licutest -licutu -licuuc
|
119
|
+
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
120
|
+
: test.o:test.cpp:(.text+0x5e): undefined reference to `icu::StringPiece::StringPiece(char const*)'
|
121
|
+
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
122
|
+
: test.o:test.cpp:(.text+0x8a): undefined reference to `icu::UnicodeString::fromUTF8(icu::StringPiec
|
123
|
+
e)'
|
124
|
+
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
125
|
+
: test.o:test.cpp:(.text+0xa5): undefined reference to `icu::UnicodeString::char32At(int) const'
|
126
|
+
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
127
|
+
: test.o:test.cpp:(.text+0x126): undefined reference to `icu::UnicodeString::~UnicodeString()'
|
128
|
+
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
129
|
+
: test.o:test.cpp:(.text+0x163): undefined reference to `icu::UnicodeString::~UnicodeString()'
|
130
|
+
collect2.exe: error: ld returned 1 exit status
|
131
|
+
make: *** [c:/CPP/_.mk:9: test.exe] Error 1
|
132
|
+
```
|
2
-lの部分はおそらくコピペミスか何かです すみません 実行しなおしてみたら-lの部分がありました
test
CHANGED
File without changes
|
test
CHANGED
@@ -93,7 +93,7 @@
|
|
93
93
|
今度はこのようなエラーが発生してしまいました
|
94
94
|
```
|
95
95
|
c:/msys64/mingw64/bin/g++ -fexec-charset=cp932 -c test.cpp
|
96
|
-
c:/msys64/mingw64/bin/g++ -o test.exe test.o -Lc:/msys64/mingw64/lib
|
96
|
+
c:/msys64/mingw64/bin/g++ -o test.exe test.o -Lc:/msys64/mingw64/lib -licudt -licuin -licuio -licutest -licutu -licuuc
|
97
97
|
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
98
98
|
: test.o:test.cpp:(.text+0x5e): undefined reference to `icu_73::StringPiece::StringPiece(char const*
|
99
99
|
)'
|
@@ -107,4 +107,5 @@
|
|
107
107
|
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
108
108
|
: test.o:test.cpp:(.text+0x163): undefined reference to `icu_73::UnicodeString::~UnicodeString()'
|
109
109
|
collect2.exe: error: ld returned 1 exit status
|
110
|
+
make: *** [C:/CPP/_.mk:9: test.exe] Error 1
|
110
111
|
```
|
1
pacmanの実行とmakefileの修正後について (遅くなってすみません)
test
CHANGED
@@ -1 +1 @@
|
|
1
|
-
No such file or directory
|
1
|
+
No such file or directory
|
test
CHANGED
@@ -74,3 +74,37 @@
|
|
74
74
|
$(CC) $(CFLAGS) -fexec-charset=cp932 $(INCDIR) -c $(SRCS)
|
75
75
|
|
76
76
|
```
|
77
|
+
|
78
|
+
だったのですがアドバイスの通りやってみたのですが、(pacmanの実行とmakefileの修正)
|
79
|
+
|
80
|
+
```makefile
|
81
|
+
CC = c:/msys64/mingw64/bin/g++
|
82
|
+
CFLAGS =
|
83
|
+
TARGET = test.exe
|
84
|
+
SRCS = test.cpp
|
85
|
+
OBJS = test.o
|
86
|
+
LIBDIR = -Lc:/msys64/mingw64/lib
|
87
|
+
LIBS = -licudt -licuin -licuio -licutest -licutu -licuuc
|
88
|
+
$(TARGET): $(OBJS)
|
89
|
+
$(CC) -o $@ $^ $(LIBDIR) $(LIBS)
|
90
|
+
$(OBJS): $(SRCS)
|
91
|
+
$(CC) $(CFLAGS) -fexec-charset=cp932 $(INCDIR) -c $(SRCS)
|
92
|
+
```
|
93
|
+
今度はこのようなエラーが発生してしまいました
|
94
|
+
```
|
95
|
+
c:/msys64/mingw64/bin/g++ -fexec-charset=cp932 -c test.cpp
|
96
|
+
c:/msys64/mingw64/bin/g++ -o test.exe test.o -Lc:/msys64/mingw64/lib
|
97
|
+
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
98
|
+
: test.o:test.cpp:(.text+0x5e): undefined reference to `icu_73::StringPiece::StringPiece(char const*
|
99
|
+
)'
|
100
|
+
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
101
|
+
: test.o:test.cpp:(.text+0x8a): undefined reference to `icu_73::UnicodeString::fromUTF8(icu_73::Stri
|
102
|
+
ngPiece)'
|
103
|
+
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
104
|
+
: test.o:test.cpp:(.text+0xa5): undefined reference to `icu_73::UnicodeString::char32At(int) const'
|
105
|
+
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
106
|
+
: test.o:test.cpp:(.text+0x126): undefined reference to `icu_73::UnicodeString::~UnicodeString()'
|
107
|
+
C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/13.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe
|
108
|
+
: test.o:test.cpp:(.text+0x163): undefined reference to `icu_73::UnicodeString::~UnicodeString()'
|
109
|
+
collect2.exe: error: ld returned 1 exit status
|
110
|
+
```
|