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

Compile error with clang #260

Closed
zhemant opened this issue Jul 23, 2024 · 1 comment
Closed

Compile error with clang #260

zhemant opened this issue Jul 23, 2024 · 1 comment

Comments

@zhemant
Copy link
Contributor

zhemant commented Jul 23, 2024

When compiling with clang, there is a no newline at end of file error. Clang needs empty line at the eof.

root@3c1cc8326686:~/zlog# CC=clang make -j4 all
cd src && make all
make[1]: Entering directory '/root/zlog/src'
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb buf.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb category.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb category_table.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb conf.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb event.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb format.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb level.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb level_list.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb mdc.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb record.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb record_table.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb rotater.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb rule.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb spec.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb thread.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb zc_arraylist.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb zc_hashtable.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb zc_profile.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb zc_util.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb lockfile.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb zlog.c
clang -std=c99 -pedantic -c -O2 -fPIC -pthread  -Wall -Werror -Wstrict-prototypes -fwrapv -g -ggdb zlog-chk-conf.c
lockfile.c:53:2: error: no newline at end of file [-Werror,-Wnewline-eof]
}
 ^
1 error generated.
make[1]: *** [Makefile:194: lockfile.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory '/root/zlog/src'
make: *** [Makefile:6: all] Error 2
@zhemant
Copy link
Contributor Author

zhemant commented Jul 24, 2024

fixed in #261

@zhemant zhemant closed this as completed Jul 24, 2024
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

1 participant