diff --git a/auto/Makefile b/auto/Makefile index eb4037b..3e04caf 100644 --- a/auto/Makefile +++ b/auto/Makefile @@ -38,8 +38,10 @@ ext: $(EXT)/.dummy $(REGISTRY)/.dummy: $(BIN)/update_registry.sh $(BIN)/update_registry.sh $(REGISTRY) $(REGISTRY_URL) - sed -e '7s/\ tmp - mv tmp $(REGISTRY)/ATI/texture_env_combine3.txt + head -6 $(REGISTRY)/ATI/texture_env_combine3.txt > tmp + tail +7 $(REGISTRY)/ATI/texture_env_combine3.txt | \ + perl -e 's/ATI\_/GL\_ATI\_/g;' -p >> tmp + mv -f tmp $(REGISTRY)/ATI/texture_env_combine3.txt touch $@ $(EXT)/.dummy: $(REGISTRY)/.dummy @@ -100,8 +102,8 @@ $(S.DEST)/glew.c: $(EXT)/.dummy $(BIN)/make_list.pl $(EXT)/GLX_* >> $@ cat $(SRC)/glew_post.c >> $@ $(BIN)/fix_OML_sync_control.sh $@ - sed -e "s/GLEW_VERSION_STRING/$(GLEW_MAJOR)\.$(GLEW_MINOR)\.$(GLEW_MICRO)/g" $@ > tmp - mv tmp $@ + perl -e "s/GLEW_VERSION_STRING/$(GLEW_MAJOR)\.$(GLEW_MINOR)\.$(GLEW_MICRO)/g" -pi.bak $@ + rm -f $@.bak $(S.DEST)/glewinfo.c: $(EXT)/.dummy cp -f $(SRC)/glewinfo_pre.c $@ diff --git a/auto/bin/update_ext.sh b/auto/bin/update_ext.sh index 7ab8dd9..a67ce2c 100755 --- a/auto/bin/update_ext.sh +++ b/auto/bin/update_ext.sh @@ -37,12 +37,12 @@ if [ ! -d $1 ] ; then # fix GL_NV_occlusion_query and GL_HP_occlusion_test grep -v '_HP' $1/GL_NV_occlusion_query > tmp mv tmp $1/GL_NV_occlusion_query - sed -e's/OCCLUSION_TEST_HP.*/OCCLUSION_TEST_HP 0x8165/' \ - $1/GL_HP_occlusion_test > tmp - mv tmp $1/GL_HP_occlusion_test - sed -e's/OCCLUSION_TEST_RESULT_HP.*/OCCLUSION_TEST_RESULT_HP 0x8166/' \ - $1/GL_HP_occlusion_test > tmp - mv tmp $1/GL_HP_occlusion_test + perl -e's/OCCLUSION_TEST_HP.*/OCCLUSION_TEST_HP 0x8165/' -pi.bak \ + $1/GL_HP_occlusion_test + rm -f $1/GL_HP_occlusion_test.bak + perl -e's/OCCLUSION_TEST_RESULT_HP.*/OCCLUSION_TEST_RESULT_HP 0x8166/' -pi.bak \ + $1/GL_HP_occlusion_test + rm -f $1/GL_HP_occlusion_test.bak # fix WGL_ATI_pixel_format_float cat >> $1/WGL_ATI_pixel_format_float < tmp - mv tmp $1/GL_ARB_vertex_shader - sed -e 's/v1/y/g' $1/GL_ARB_vertex_shader > tmp - mv tmp $1/GL_ARB_vertex_shader - sed -e 's/v2/z/g' $1/GL_ARB_vertex_shader > tmp - mv tmp $1/GL_ARB_vertex_shader - sed -e 's/v3/w/g' $1/GL_ARB_vertex_shader > tmp - mv tmp $1/GL_ARB_vertex_shader + perl -e 's/v0/x/g' -pi.bak $1/GL_ARB_vertex_shader + rm -f $1/GL_ARB_vertex_shader.bak + perl -e 's/v1/y/g' -pi.bak $1/GL_ARB_vertex_shader + rm -f $1/GL_ARB_vertex_shader.bak + perl -e 's/v2/z/g' -pi.bak $1/GL_ARB_vertex_shader + rm -f $1/GL_ARB_vertex_shader.bak + perl -e 's/v3/w/g' -pi.bak $1/GL_ARB_vertex_shader + rm -f $1/GL_ARB_vertex_shader.bak # remove triplicates in GL_ARB_shader_objects, GL_ARB_fragment_shader, # and GL_ARB_vertex_shader @@ -136,8 +136,8 @@ EOT # fix bugs in GL_ARB_vertex_shader grep -v "GL_FLOAT" $1/GL_ARB_vertex_shader > tmp mv tmp $1/GL_ARB_vertex_shader - sed -e 's/handle /GLhandleARB /g' $1/GL_ARB_vertex_shader > tmp - mv tmp $1/GL_ARB_vertex_shader + perl -e 's/handle /GLhandleARB /g' -pi.bak $1/GL_ARB_vertex_shader + rm -f $1/GL_ARB_vertex_shader.bak # fix bugs in GL_ARB_shader_objects grep -v "GL_FLOAT" $1/GL_ARB_shader_objects > tmp